Closed ErisDS closed 5 years ago
Some of this is outdated, but I'm sure there are plenty more small tasks like this that have cropped up in the year since I wrote this.
https://github.com/TryGhost/Ghost/commit/bdd57b36cfc382f4d1df872834a8e99b4a4ba359 Removed a layer of indentation from the Gruntfile, I don't think we can remove much more due to the way grunt injects itself, e.g.
module.exports = function (grunt) {
// Do stuff w/ grunt here, nested one level
}
Note the grunt master
command is currently broken - if you try to run it when the submodules are out of date it errors, rather than updating them, which is its job!
@ErisDS I'll take a look at that
Broken for me too
Ok I ran it 3 more times and it timed out in different places each time and then eventually completed
^ looks this was a network/yarn issue rather than the grunt task :relaxed:
grunt release creates a zip with contents which do not equal .tgz
After creating a release zip and using npm pack
to create a tarball, I extracted them to a zip
and tgz
directory respectively.
>> diff -r tgz/ zip/
Only in tgz/content/themes/casper/assets/css: .csscomb.json
Only in zip/content/themes/casper: config.example.json
Only in tgz/content/themes/casper: .yarnrc
Only in zip/core/server/lib/members/static/auth: dist
Only in zip/core/server/lib/members/static/auth: index.html
Only in zip/core/server/lib/members/static/gateway: index.html
Only in tgz/core/server/web/admin/views: .gitkeep
Only in tgz/: .eslintignore
Only in tgz/: .eslintrc.json
Only in tgz/: .npmignore
Will work on resolving these differences
The output tars/zipz of grunt release
and npm pack
now unpack to the same directories, apart from these two files:
>> diff -r tgz/ zip/
Only in zip/core/server/lib/members/static/auth: dist
Only in zip/core/server/lib/members/static/auth: index.html
This will be fixed when members has been moved into it's own monorepo.which is tracked here: https://github.com/TryGhost/Ghost/issues/10701
Closing this now :tada:
This issue contains a list of mostly small cleanup tasks for our tooling.
Aim is to move towards consistency between repos (both public and private) to lean on package.json scripts more heavily where possible, simplify grunt & essentially make this repo neater & easier to use š
grunt run
orgrunt shell
instead cos it's more generic, and we can do other things this waylint
as a script in package.jsongrunt release
creates a zip with contents which do not equal .tgz (e.g. https://github.com/TryGhost/Ghost/commit/0db01a02374bfddcca08fb9ecd2286d078f9a74c)grunt master
fail when working tree is not clean