Skip to content

Commit

Permalink
Update deps, switch to actions (#141)
Browse files Browse the repository at this point in the history
* Update deps, switch to actions

* Fix actions dir

* Use npm i for actions
  • Loading branch information
vladikoff committed Mar 13, 2021
1 parent 84ebcb8 commit c271173
Show file tree
Hide file tree
Showing 5 changed files with 61 additions and 63 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Tests

on: [push, pull_request]

env:
FORCE_COLOR: 2

jobs:
run:
name: Node ${{ matrix.node }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}

strategy:
fail-fast: false
matrix:
node: [10, 12, 14]
os: [ubuntu-latest, windows-latest]

steps:
- name: Clone repository
uses: actions/checkout@v2

- name: Set up Node.js
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node }}

- name: Install npm dependencies
run: npm i

- name: Run tests
run: npm test

# We test multiple Windows shells because of prior stdout buffering issues
# filed against Grunt. https://github.com/joyent/node/issues/3584
- name: Run PowerShell tests
run: "npm test # PowerShell" # Pass comment to PS for easier debugging
shell: powershell
if: startsWith(matrix.os, 'windows')
6 changes: 0 additions & 6 deletions .travis.yml

This file was deleted.

37 changes: 0 additions & 37 deletions appveyor.yml

This file was deleted.

38 changes: 20 additions & 18 deletions bin/grunt
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

process.title = 'grunt';

var Liftoff = require('liftoff');
var Liftup = require('liftup');
var v8flags = require('v8flags');
var extensions = require('interpret').jsVariants;
var nopt = require('nopt');
Expand Down Expand Up @@ -35,35 +35,37 @@ if ('completion' in options) {
}

v8flags(function (err, v8flags) {
var Grunt = new Liftoff({
var Grunt = new Liftup({
name: 'grunt',
configName: 'Gruntfile',
// Support a number of languages based on file extension
extensions: extensions,
// Flags that are v8 flags will be loaded into node instead of Gruntfile
v8flags: v8flags
});
Grunt.launch({
Grunt.prepare({
cwd: options.base,
configPath: options.gruntfile,
require: options.require,
verbose: options.verbose
}, function (env) {
var tasks = options.argv.remain;
delete options.argv;
// No grunt install found!
if (!env.modulePath) {
if (options.version) {
process.exit();
Grunt.execute(env, function(env) {
var tasks = options.argv.remain;
delete options.argv;
// No grunt install found!
if (!env.modulePath) {
if (options.version) {
process.exit();
}
if (options.help) {
info.help();
}
info.fatal('Unable to find local grunt.', 99);
} else {
options.gruntfile = env.configPath;
var grunt = require(env.modulePath);
grunt.tasks(tasks, options);
}
if (options.help) {
info.help();
}
info.fatal('Unable to find local grunt.', 99);
} else {
options.gruntfile = env.configPath;
var grunt = require(env.modulePath);
grunt.tasks(tasks, options);
}
});
});
});
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@
"dependencies": {
"grunt-known-options": "~1.1.1",
"interpret": "~1.1.0",
"liftoff": "~2.5.0",
"liftup": "~3.0.1",
"nopt": "~4.0.1",
"v8flags": "~3.2.0"
},
"devDependencies": {
"grunt": "~1.3.0",
"grunt-contrib-jshint": "~2.1.0"
"grunt-contrib-jshint": "~3.0.0"
},
"files": [
"bin",
Expand Down

0 comments on commit c271173

Please sign in to comment.