mirror of
https://github.com/danog/dart-sass.git
synced 2025-01-22 05:41:14 +01:00
Add a dev dependency on fibers from NPM
This commit is contained in:
parent
7178a91844
commit
0a67d3845f
1
.gitignore
vendored
1
.gitignore
vendored
@ -8,3 +8,4 @@ packages
|
|||||||
.packages
|
.packages
|
||||||
pubspec.lock
|
pubspec.lock
|
||||||
/benchmark/source
|
/benchmark/source
|
||||||
|
node_modules/
|
||||||
|
@ -43,7 +43,7 @@ install:
|
|||||||
- if-node . "$HOME/.nvm/nvm.sh"
|
- if-node . "$HOME/.nvm/nvm.sh"
|
||||||
- if-node nvm install "$NODE_VERSION"
|
- if-node nvm install "$NODE_VERSION"
|
||||||
- if-node nvm use "$NODE_VERSION"
|
- if-node nvm use "$NODE_VERSION"
|
||||||
- SASS_MINIFY_JS=false if-node pub run grinder npm_package
|
- SASS_MINIFY_JS=false if-node pub run grinder before_test
|
||||||
|
|
||||||
# Download sass-spec and install its dependencies if we're running specs.
|
# Download sass-spec and install its dependencies if we're running specs.
|
||||||
- if-specs() { if [ "$TASK" = specs ]; then "$@"; fi }
|
- if-specs() { if [ "$TASK" = specs ]; then "$@"; fi }
|
||||||
|
9
package.json
Normal file
9
package.json
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
{
|
||||||
|
"//": [
|
||||||
|
"This isn't the official package.json for Dart Sass. It's just used to ",
|
||||||
|
"install dependencies used for testing the Node API."
|
||||||
|
],
|
||||||
|
"devDependencies": {
|
||||||
|
"fibers": ">=1.0.0 <3.0.0"
|
||||||
|
}
|
||||||
|
}
|
@ -36,6 +36,6 @@ dev_dependencies:
|
|||||||
stream_channel: "^1.0.0"
|
stream_channel: "^1.0.0"
|
||||||
test_descriptor: "^1.0.0"
|
test_descriptor: "^1.0.0"
|
||||||
test_process: "^1.0.0-rc.1"
|
test_process: "^1.0.0-rc.1"
|
||||||
test: "^0.12.26"
|
test: "^0.12.29"
|
||||||
xml: "^2.4.0"
|
xml: "^2.4.0"
|
||||||
yaml: "^2.0.0"
|
yaml: "^2.0.0"
|
||||||
|
@ -32,7 +32,7 @@ hybridMain(StreamChannel channel) async {
|
|||||||
var entryLastModified = entry.lastModifiedSync();
|
var entryLastModified = entry.lastModifiedSync();
|
||||||
if (lastModified.isBefore(entryLastModified)) {
|
if (lastModified.isBefore(entryLastModified)) {
|
||||||
throw "${entry.path} was modified after NPM package was generated.\n"
|
throw "${entry.path} was modified after NPM package was generated.\n"
|
||||||
"Run pub run grinder npm_package.";
|
"Run pub run grinder before_test.";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -38,10 +38,8 @@ final _sdkDir = p.dirname(p.dirname(Platform.resolvedExecutable));
|
|||||||
main(List<String> args) => grind(args);
|
main(List<String> args) => grind(args);
|
||||||
|
|
||||||
@DefaultTask('Compile async code and reformat.')
|
@DefaultTask('Compile async code and reformat.')
|
||||||
all() {
|
@Depends(format, synchronize)
|
||||||
format();
|
all() {}
|
||||||
synchronize();
|
|
||||||
}
|
|
||||||
|
|
||||||
@Task('Run the Dart formatter.')
|
@Task('Run the Dart formatter.')
|
||||||
format() {
|
format() {
|
||||||
@ -100,6 +98,13 @@ npm_package() {
|
|||||||
_writeNpmPackage('build/npm-old', json..addAll({"name": "dart-sass"}));
|
_writeNpmPackage('build/npm-old', json..addAll({"name": "dart-sass"}));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Task('Installs dependencies from npm.')
|
||||||
|
npm_install() => run("npm", arguments: ["install"]);
|
||||||
|
|
||||||
|
@Task('Runs the tasks that are required for running tests.')
|
||||||
|
@Depends(npm_package, npm_install)
|
||||||
|
before_test() {}
|
||||||
|
|
||||||
/// Writes a Dart Sass NPM package to the directory at [destination].
|
/// Writes a Dart Sass NPM package to the directory at [destination].
|
||||||
///
|
///
|
||||||
/// The [json] will be used as the package's package.json.
|
/// The [json] will be used as the package's package.json.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user