Skip to content

Remove closure compilation from the CLI #155

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

Merged
merged 1 commit into from
Jun 10, 2016

Conversation

jjudd
Copy link
Contributor

@jjudd jjudd commented Jun 10, 2016

This removes the need for google-closure-compiler to be a dependency. Now
it can be a dev dependency and the CLI should just work when downloaded
from npm.

@@ -76,8 +67,8 @@ function loadSettingsFromArgs(args: string[]): {settings: Settings, tscArgs: str
process.exit(1);
}
}
if (!settings.outputPath && !settings.externsPath) {
console.error('must specify --output or --externs path');
if (!settings.externsPath) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because this is required, it might be worth making this an argument instead of an option. Alternatively, do not make it required.

@jjudd
Copy link
Contributor Author

jjudd commented Jun 10, 2016

This would resolve #153, it does not have the rest of the enhancements discussed there, but this gets the npm package working without needing the google-closure-compiler installed.

This removes the need for google-closure-compiler to be a dependency. Now
it can be a dev dependency and the CLI should just work when downloaded
from npm.

Because the closure compiler has been removed, temporary files are always
output because tsickle is now a wrapper around the TypeScript compiler.
@jjudd jjudd force-pushed the remove-closure-compilation branch from 2c4bf81 to 957ec2e Compare June 10, 2016 16:42
fs.writeFileSync(fileName, jsFiles[fileName]);
}
for (let fileName of Object.keys(jsFiles)) {
fs.writeFileSync(fileName, jsFiles[fileName]);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Does this always write the files next to the .ts files? Or does it obey outDir? Just curious.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

As far as I can tell, it obeys all the output rules of the TypeScript compiler. We're using outDir without any problems.

@evmar evmar merged commit 60e669c into angular:master Jun 10, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants