Skip to content

Commit

Permalink
Include additional VCS directories to ignore (#683)
Browse files Browse the repository at this point in the history
npm’s list is incomplete for VCSs. Since they can sometimes execute
scripts without the users knowledge & since only the source, not the
entire history, is needed, it should be safe to ignore them.
Additionally clarified these as a separate bullet point in the spec.
  • Loading branch information
toastal authored Jan 19, 2024
1 parent 4cd57a1 commit ef989a1
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion SPEC.md
Original file line number Diff line number Diff line change
Expand Up @@ -426,7 +426,8 @@ These files are always included in the tarball, if present:

These files are always excluded from the tarball, regardless of what is specified in the `files` key:

- `.psci`, `.psci_modules`, `.spago`, `node_modules`, `bower_components`, `.git`, `CVS`, `.svn`, and `.hg` directories.
- `.psci`, `.psci_modules`, `.spago`, `node_modules`, and `bower_components` directories.
- `.git`, `CVS`, `.svn`, `.hg`, `_darcs`, `.fossil`, `.jj`, and `.pijul` <abbr title="version control system">VCS</abbr> directories.
- `package-lock.json`, `yarn.lock`, and `pnpm-lock.yaml` files.
- `.swp`, `._*`, and `.DS_Store` files.

Expand Down
5 changes: 5 additions & 0 deletions lib/src/Constants.purs
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,11 @@ ignoredDirectories =
, "CVS"
, ".svn"
, ".hg"
-- Additional VCS directories
, "_darcs"
, ".fossil"
, ".jj"
, ".pijul"
]

ignoredFiles :: Array FilePath
Expand Down

0 comments on commit ef989a1

Please sign in to comment.