Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/alpha' into alpha
Browse files Browse the repository at this point in the history
  • Loading branch information
oprypkhantc committed Apr 23, 2024
2 parents 0e7f297 + 8739a27 commit aa8c53a
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 4 deletions.
7 changes: 7 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,10 @@
# [1.0.0-alpha.6](https://github.com/tenantcloud/template-sync/compare/v1.0.0-alpha.5...v1.0.0-alpha.6) (2024-04-23)


### Bug Fixes

* Glob ignores dot directories/files ([4d9beb2](https://github.com/tenantcloud/template-sync/commit/4d9beb2556f2aafb698e29d3722c9994ae025907))

# [1.0.0-alpha.5](https://github.com/tenantcloud/template-sync/compare/v1.0.0-alpha.4...v1.0.0-alpha.5) (2024-04-23)


Expand Down
17 changes: 13 additions & 4 deletions dist/github-action/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -43388,6 +43388,8 @@ var external_os_ = __nccwpck_require__(2037);
var external_path_ = __nccwpck_require__(1017);
;// CONCATENATED MODULE: external "node:crypto"
const external_node_crypto_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:crypto");
// EXTERNAL MODULE: ./node_modules/remeda/dist/commonjs/index.js
var commonjs = __nccwpck_require__(8886);
;// CONCATENATED MODULE: external "node:process"
const external_node_process_namespaceObject = __WEBPACK_EXTERNAL_createRequire(import.meta.url)("node:process");
;// CONCATENATED MODULE: external "node:fs"
Expand Down Expand Up @@ -44071,11 +44073,15 @@ const generateGlobTasksSync = normalizeArgumentsSync(generateTasksSync);

const {convertPathToPattern} = out;

// EXTERNAL MODULE: ./node_modules/remeda/dist/commonjs/index.js
var commonjs = __nccwpck_require__(8886);
;// CONCATENATED MODULE: ./src/repositories/repository.ts
;// CONCATENATED MODULE: ./src/glob.ts


async function glob(patterns, root, ignore = []) {
return commonjs.difference.multiset(await globby(patterns, { cwd: root, dot: true }), ignore);
}

;// CONCATENATED MODULE: ./src/repositories/repository.ts


class Repository {
root;
Expand All @@ -44086,7 +44092,7 @@ class Repository {
return (0,external_path_.join)(this.root, relative);
}
async files(patterns = ["**/*"], ignore = []) {
return commonjs.difference.multiset(await globby(patterns, { cwd: this.root }), ignore);
return await glob(patterns, this.root, ignore);
}
}

Expand Down Expand Up @@ -52975,6 +52981,8 @@ async function loadConfigFromPossible(root, possibleFileNames) {





const optionsSchema = z.strictObject({
filter: z.array(z.string()).default(["**/*"]),
deleteExtra: z.boolean().default(true),
Expand All @@ -52984,6 +52992,7 @@ const optionsSchema = z.strictObject({
return async function (template, source, reserved) {
const templateFiles = await template.files(options.filter, reserved);
for (const file of templateFiles) {
await (0,lib.ensureDir)((0,external_path_.dirname)(source.path(file)));
await (0,external_fs_promises_namespaceObject.copyFile)(template.path(file), source.path(file));
}
if (options.deleteExtra) {
Expand Down

0 comments on commit aa8c53a

Please sign in to comment.