Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Decaf Source #84

Merged
merged 62 commits into from
Jul 23, 2023
Merged
Changes from 1 commit
Commits
Show all changes
62 commits
Select commit Hold shift + click to select a range
16e0075
Decaf all files
confused-Techie Jul 22, 2023
8f7d7ff
Re-decaf with `--optional-chaining`
confused-Techie Jul 22, 2023
d618f1b
Fully Decaf `apm-cli.js`
confused-Techie Jul 22, 2023
6fb3c15
Remove decaf message, and finish decaffing `apm-cli.js`
confused-Techie Jul 22, 2023
2cc8022
Decaf `apm.js`
confused-Techie Jul 22, 2023
a5b1b88
Decaf `auth.js`
confused-Techie Jul 22, 2023
81aa85f
Decaf `ci.js`
confused-Techie Jul 22, 2023
9007336
Decaf `clean.js`
confused-Techie Jul 22, 2023
1e8edbc
Decaf `cli.js`
confused-Techie Jul 22, 2023
a530cbb
Decaf `command.js`
confused-Techie Jul 23, 2023
7300686
Decaf `config.js`
confused-Techie Jul 23, 2023
00f2a19
Remove `Config` variable from `config.js`
confused-Techie Jul 23, 2023
74f443c
Fix typo in `clean.js`
confused-Techie Jul 23, 2023
0f9c924
Decaf `dedupe`
confused-Techie Jul 23, 2023
4586429
decaf `deprecated-packages`
confused-Techie Jul 23, 2023
a6896a3
Decaf `develop`
confused-Techie Jul 23, 2023
7d576a4
Fix spacing on clean output
confused-Techie Jul 23, 2023
c9455df
Decaf `disable`
confused-Techie Jul 23, 2023
907b278
decaf `docs`
confused-Techie Jul 23, 2023
7b6a393
decaf `enable`
confused-Techie Jul 23, 2023
fb9ff1e
decaf `featured`
confused-Techie Jul 23, 2023
44d8b96
decaf `fs`
confused-Techie Jul 23, 2023
20dc881
decaf `git`
confused-Techie Jul 23, 2023
12a5880
decaf `init`
confused-Techie Jul 23, 2023
f9f0b07
Light decaf of `install`
confused-Techie Jul 23, 2023
83dd4c6
Decaf `link`
confused-Techie Jul 23, 2023
fd29416
Realizing that output strings have been being formatted incorrectly
confused-Techie Jul 23, 2023
ec3f569
decaf `link`
confused-Techie Jul 23, 2023
c12f9af
decaf `list`
confused-Techie Jul 23, 2023
97e1d60
decaf `login`
confused-Techie Jul 23, 2023
d233db8
decaf `package-converter`
confused-Techie Jul 23, 2023
de1221e
decaf `packages`
confused-Techie Jul 23, 2023
45e3cdc
decaf `publish`
confused-Techie Jul 23, 2023
ebd1e1f
decaf `rebuild-module-cache`
confused-Techie Jul 23, 2023
e121a18
decaf `rebuild`
confused-Techie Jul 23, 2023
9d99353
decaf `request`
confused-Techie Jul 23, 2023
a958bc0
decaf `search`
confused-Techie Jul 23, 2023
57e4809
decaf `star`
confused-Techie Jul 23, 2023
2e399fb
decaf `stars`
confused-Techie Jul 23, 2023
28cfb52
decaf `test`
confused-Techie Jul 23, 2023
3b4a6b7
decaf `text-mate-theme`
confused-Techie Jul 23, 2023
3e586ea
decaf `theme-converter`
confused-Techie Jul 23, 2023
6748e1f
decaf `tree`
confused-Techie Jul 23, 2023
b923023
decaf `uninstall`
confused-Techie Jul 23, 2023
4228c96
decaf `unlink`
confused-Techie Jul 23, 2023
5b5cecc
decaf `unpublish`
confused-Techie Jul 23, 2023
d41a667
decaf `unstar`
confused-Techie Jul 23, 2023
93411a1
decaf `updade`
confused-Techie Jul 23, 2023
127baba
decaf `view`
confused-Techie Jul 23, 2023
b87f934
Migrate all tests and build tools to new decaffed code
confused-Techie Jul 23, 2023
d2fe84b
Use normal testing
confused-Techie Jul 23, 2023
14a3a0e
Revert changes to tests, adding comment for future use
confused-Techie Jul 23, 2023
27521b3
Maybe a require error is being eaten in tests
confused-Techie Jul 23, 2023
8efefed
Fix another bad import
confused-Techie Jul 23, 2023
4670a95
temp verbose logging
confused-Techie Jul 23, 2023
6c10eec
Ensure we return all yargs parsed parameters
confused-Techie Jul 23, 2023
d0b8f94
Remove debugging throw
confused-Techie Jul 23, 2023
f874cde
Setting `supportedSyntaxes` as standard property
confused-Techie Jul 23, 2023
8279b8a
Remove verbose flag from ci
confused-Techie Jul 23, 2023
75fdc45
Resolve case in `supportedSyntaxes`
confused-Techie Jul 23, 2023
a3cd921
Can we enable testing for windows?
confused-Techie Jul 23, 2023
e18f0b2
Revert "Can we enable testing for windows?"
confused-Techie Jul 23, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Remove decaf message, and finish decaffing apm-cli.js
  • Loading branch information
confused-Techie committed Jul 22, 2023
commit 6fb3c15f51dc568f06808aac89bfd89dab97dad2
14 changes: 2 additions & 12 deletions src/apm-cli.js
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
/*
* decaffeinate suggestions:
* DS101: Remove unnecessary use of Array.from
* DS102: Remove unnecessary code created because of implicit returns
* DS104: Avoid inline assignments
* DS207: Consider shorter variations of null checks
* Full docs: https://github.com/decaffeinate/decaffeinate/blob/main/docs/suggestions.md
*/
const {spawn} = require('child_process');
const path = require('path');

Expand Down Expand Up @@ -163,8 +155,7 @@ ${'git'.magenta} ${gitVersion.magenta}\
var getAtomVersion = callback => config.getResourcePath(function(resourcePath) {
const unknownVersion = 'unknown';
try {
let left;
const {version} = (left = require(path.join(resourcePath, 'package.json'))) != null ? left : unknownVersion;
const { version } = require(path.join(resourcePath, "package.json")) ?? unknownVersion;
return callback(version);
} catch (error) {
return callback(unknownVersion);
Expand All @@ -177,8 +168,7 @@ var getPythonVersion = function(callback) {
globalconfig: config.getGlobalConfigPath()
};
return npm.load(npmOptions, function() {
let left;
let python = (left = npm.config.get('python')) != null ? left : process.env.PYTHON;
let python = npm.config.get("python") ?? process.env.PYTHON;
if (config.isWin32() && !python) {
let rootDir = process.env.SystemDrive != null ? process.env.SystemDrive : 'C:\\';
if (rootDir[rootDir.length - 1] !== '\\') { rootDir += '\\'; }
Expand Down