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
Split coffeescript package, part 2 #9018
Split coffeescript package, part 2 #9018
Conversation
…e. (meteor#8960) They depend on core packages like caching-compiler, but coffeescript-compiler can remain in non-core, so it can update more frequently as npm coffeescript gets updated.
This Meteor package version does not need to track the npm version of the coffeescript package, and probably should not change as often as the version of the packages/non-core/coffeescript-compiler package.
…; update documentation
api.use('babel-compiler@6.19.4'); | ||
api.use('ecmascript@0.8.2'); | ||
|
||
api.addFiles(['coffeescript-compiler.js'], 'server'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since you're using ecmascript
, I would make this
api.mainModule("coffeescript-compiler.js", "server");
|
||
|
||
// The CompileResult for this CachingCompiler is a {source, sourceMap} object. | ||
CoffeeScriptCompiler = class CoffeeScriptCompiler { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you use api.mainModule
in package.js
, then this line can just be
export class CoffeeScriptCompiler {
and api.export("CoffeeScriptCompiler", "server")
will use the exported CoffeeScriptCompiler
.
@@ -1,29 +1,29 @@ | |||
Package.describe({ | |||
summary: "Javascript dialect with fewer braces and semicolons", | |||
version: "1.12.6_1" | |||
name: 'coffeescript', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Glad to have a name here now!
"source-map": "0.5.6" | ||
} | ||
name: 'compile-coffeescript', | ||
use: ['caching-compiler@1.1.9', 'ecmascript@0.8.2', 'coffeescript-compiler@1.12.7_1'], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the record, this means an application developer who's using coffeescript
can use any version of caching-compiler
that's >= 1.1.9
and has the same major version (1.x.y
). Likewise, any version of ecmascript
is fair game if it starts with a 0.
and is more recent than 0.8.2
.
Should we make the coffeescript-compiler
version constraint exact (@=1.12.7_1
)? Do you think users might ever want to use different versions of coffeescript
and coffeescript-compiler
?
Looks like Circle CI is having problems right now, by the way: https://status.circleci.com/ |
@benjamn I’ve revised per your notes. |
api.use('babel-compiler@6.19.4'); | ||
api.use('ecmascript@0.8.2'); | ||
|
||
api.mainModule(['coffeescript-compiler.js'], 'server'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line is causing some legit test failures. It should just be a string, not an array (as there can be only one main module):
api.mainModule('coffeescript-compiler.js', 'server');
I tried pushing a commit to this branch, but I think only you can do that, @GeoffreyBooth.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Updated. I have “allow edits from maintainers” checked, so I’d think you should be able to push commits . . .
Looks like the build passed! |
Are you able to republish the packages, or should I? |
I don't think I am . . . ? |
Are you fine with me publishing them now, then? |
Of course. |
Small follow-up to #9018. Note (especially @GeoffreyBooth): these version constraints do two things: (1) specify a minimum version, and (2) fix the major version. In other words, the coffeescript package should not need to be republished when we publish new minor versions of these core packages in Meteor 1.5.2 or 1.6. When/if we publish a new major version of these packages, the coffeescript package can simply bump its version constraints, but that probably won't happen any time soon. I think that's reasonable because a major version bump suggests there are some significant changes that need to be acknowledged by dependent packages.
Okay! All three packages have been published, and I can confirm that I get the new versions when I run 1:~/dev/coffee-split-test% ~/.meteor/meteor --version
Meteor 1.5.1
1:~/dev/coffee-split-test% ~/.meteor/meteor add coffeescript
Changes to your project's package version selections:
coffeescript added, version 1.12.7_1
coffeescript-compiler added, version 1.12.7_1
coffeescript: Javascript dialect with fewer braces and semicolons |
This will make it easier to merge devel into release-1.5.2, since devel now contains the final verison of these changes, as implemented by @GeoffreyBooth in #9018. Revert "Bump coffeescript package version to 1.13.0." This reverts commit d727ad0. Revert "Move coffeescript and coffeescript-test-helper packages back into core. (#8960)" This reverts commit eb3c7dd. Revert "Split coffeescript package into coffeescript / coffeescript-compiler." This reverts commit 8344cbf. Revert "Instructions for how to test the coffeescript package" This reverts commit 491cbc3.
Thanks! |
Thank you for all your work on this, @GeoffreyBooth! |
See #8960.