Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(generators): added .gitattributes file #108

Merged
merged 1 commit into from
Dec 14, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions e2e/scfz.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@ describe("e2e", () => {
"environments",
"docs",
"decisions",
".gitattributes",
".gitignore",
"scripts",
"containers",
Expand Down
5 changes: 5 additions & 0 deletions lib/generators/workspace.ts
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,11 @@ const generator: GeneratorDefinition<WorkspaceAnswers> = {
path: "architecture/.gitignore",
templateFile: "templates/.gitignore",
} as AddAction<WorkspaceAnswers>,
{
type: "add",
path: "architecture/.gitattributes",
templateFile: "templates/.gitattributes",
} as AddAction<WorkspaceAnswers>,
{
type: "add",
path: "architecture/.env-arch",
Expand Down
1 change: 1 addition & 0 deletions lib/templates/.gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
workspace.json binary
2 changes: 2 additions & 0 deletions lib/templates/bundle.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import envArch from "./.env-arch.hbs";
import gitattributes from "./.gitattributes";
import gitignore from "./.gitignore";
import componentsComponent from "./components/component.hbs";
import constant from "./constant.hbs";
Expand All @@ -24,6 +25,7 @@ import workspace from "./workspace.hbs";

const templatesMap = new Map([
["templates/.env-arch", envArch],
["templates/.gitattributes", gitattributes],
["templates/.gitignore", gitignore],
["templates/components/component.hbs", componentsComponent],
["templates/constant.hbs", constant],
Expand Down
6 changes: 6 additions & 0 deletions lib/types.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,12 @@ declare module "*.gitignore" {
export default content;
}

declare module "*.gitattributes" {
const content: string;

export default content;
}

declare module "*.sh" {
const content: string;

Expand Down
Loading