@salesforce/source-tracking 1.0.1 → 1.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +6 -0
- package/lib/shared/localShadowRepo.js +2 -5
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,12 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
+
### [1.0.2](https://github.com/forcedotcom/source-tracking/compare/v1.0.1...v1.0.2) (2022-01-25)
|
|
6
|
+
|
|
7
|
+
### Bug Fixes
|
|
8
|
+
|
|
9
|
+
- handle gitignore outside pkgDirs ([23a65c8](https://github.com/forcedotcom/source-tracking/commit/23a65c89c8b55525b5d8efe88195d734d337d82a))
|
|
10
|
+
|
|
5
11
|
### [1.0.1](https://github.com/forcedotcom/source-tracking/compare/v1.0.0...v1.0.1) (2022-01-25)
|
|
6
12
|
|
|
7
13
|
### Bug Fixes
|
|
@@ -50,6 +50,7 @@ class ShadowRepo {
|
|
|
50
50
|
this.logger.debug('initializing git repo');
|
|
51
51
|
await this.gitInit();
|
|
52
52
|
}
|
|
53
|
+
await this.locateIgnoreFiles();
|
|
53
54
|
}
|
|
54
55
|
/**
|
|
55
56
|
* Initialize a new source tracking shadow repo. Think of git init
|
|
@@ -58,7 +59,6 @@ class ShadowRepo {
|
|
|
58
59
|
async gitInit() {
|
|
59
60
|
await core_1.fs.promises.mkdir(this.gitDir, { recursive: true });
|
|
60
61
|
await git.init({ fs: core_1.fs, dir: this.projectPath, gitdir: this.gitDir, defaultBranch: 'main' });
|
|
61
|
-
await this.locateIgnoreFiles();
|
|
62
62
|
}
|
|
63
63
|
/**
|
|
64
64
|
* Delete the local tracking files
|
|
@@ -215,13 +215,10 @@ class ShadowRepo {
|
|
|
215
215
|
dir: this.projectPath,
|
|
216
216
|
gitdir: this.gitDir,
|
|
217
217
|
trees: [git.WORKDIR()],
|
|
218
|
-
// TODO: this can be marginally faster if we limit it to pkgDirs and toplevel project files
|
|
219
218
|
// eslint-disable-next-line @typescript-eslint/require-await
|
|
220
219
|
map: async (filepath) => filepath,
|
|
221
220
|
}))
|
|
222
|
-
.filter((filepath) => filepath.includes(gitIgnoreFileName)
|
|
223
|
-
// can be top-level like '.' (no sep) OR must be in one of the package dirs
|
|
224
|
-
(!filepath.includes(path.sep) || this.packageDirs.some((dir) => (0, functions_1.pathIsInFolder)(filepath, dir.name))))
|
|
221
|
+
.filter((filepath) => filepath.includes(gitIgnoreFileName))
|
|
225
222
|
.map((ignoreFile) => path.join(this.projectPath, ignoreFile));
|
|
226
223
|
}
|
|
227
224
|
async stashIgnoreFile() {
|
package/package.json
CHANGED