Skip to content
This repository was archived by the owner on Jan 26, 2024. It is now read-only.

Commit aa0f173

Browse files
committed
first release to NPM as @angular-schule/ngx-deploy-starter
renamed to show how scoped packages work (which is likely to be used more often)
1 parent 3121742 commit aa0f173

File tree

10 files changed

+27
-22
lines changed

10 files changed

+27
-22
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# ngx-deploy-starter
1+
# @angular-schule/ngx-deploy-starter 🚀
22

33
## About
44

@@ -50,7 +50,7 @@ We appreciate your [feedback](https://github.com/angular-schule/ngx-deploy-start
5050

5151
1. fork this repository
5252
2. adjust the `package.json`
53-
3. search and replace for the string `ngx-deploy-starter` and choose your own name.
53+
3. search and replace for the string `@angular-schule/ngx-deploy-starter` and `ngx-deploy-starter` and choose your own name.
5454
4. search and replace for the string `to the file system` and name your deploy target.
5555
5. add your deployment code to `src/engine/engine.ts`, take care of the tests
5656
6. follow the instructions from the [contributors README](docs/README_contributors.md) for build, test and publishing.

docs/README_contributors.md

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# ngx-deploy-starter: README for contributors
1+
# @angular-schule/ngx-deploy-starter: README for contributors
22

33
## How to start <a name="start"></a>
44

@@ -39,7 +39,7 @@ Follow the instructions for [checking and updating the Angular CLI version](#ang
3939

4040
### 2. npm link
4141

42-
Use the following instructions to make `ngx-deploy-starter` available locally via `npm link`.
42+
Use the following instructions to make `@angular-schule/ngx-deploy-starter` available locally via `npm link`.
4343

4444
1. Clone the project
4545

@@ -73,29 +73,34 @@ Read more about the `link` feature in the [official NPM documentation](https://d
7373

7474
### 3. Adding to an Angular project -- ng add
7575

76-
Once you have completed the previous steps to `npm link` the local copy of `ngx-deploy-starter`, follow these steps to use it in a local Angular project.
76+
Once you have completed the previous steps to `npm link` the local copy of `@angular-schule/ngx-deploy-starter`, follow these steps to use it in a local Angular project.
7777

7878
1. Enter the project directory
7979

8080
```sh
8181
cd your-angular-project
8282
```
8383

84-
2. Add the local version of `ngx-deploy-starter`.
84+
2. Add the local version of `@angular-schule/ngx-deploy-starter`.
8585

8686
```sh
87-
npm link ngx-deploy-starter
87+
npm link @angular-schule/ngx-deploy-starter
8888
```
8989

9090
3. Now execute the `ng-add` schematic.
9191

9292
```sh
93-
ng add ngx-deploy-starter
93+
ng add @angular-schule/ngx-deploy-starter
9494
```
9595

9696
4. You can now deploy your angular app to GitHub pages.
9797

9898
```sh
99+
ng deploy
100+
```
101+
102+
Which is the same as:
103+
```
99104
ng run your-angular-project:deploy
100105
```
101106

@@ -120,5 +125,5 @@ npm test
120125
cd ngx-deploy-starter/src
121126
npm run build
122127
npm run test
123-
npm publish dist
128+
npm publish dist --access public
124129
```

src/README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
# ngx-deploy-starter
1+
# @angular-schule/ngx-deploy-starter
22

33
**Deploy your Angular app to the file system directly from the Angular CLI! 🚀**
44

@@ -11,10 +11,10 @@
1111
1212
## Usage
1313

14-
Add `ngx-deploy-starter` to your project.
14+
Add `@angular-schule/ngx-deploy-starter` to your project.
1515

1616
```bash
17-
ng add ngx-deploy-starter
17+
ng add @angular-schule/ngx-deploy-starter
1818
```
1919

2020
Deploy your project to the file system.

src/collection.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"$schema": "@angular-devkit/schematics/collection-schema.json",
33
"schematics": {
44
"ng-add": {
5-
"description": "Add ngx-deploy-starter deploy schematic",
5+
"description": "Add @angular-schule/ngx-deploy-starter deploy schematic",
66
"factory": "./ng-add#ngAdd"
77
}
88
}

src/deploy/schema.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"id": "Schema",
33
"title": "schema",
4-
"description": "Deployment of Angular CLI applications to GitHub pages (ngx-deploy-starter)",
4+
"description": "Deployment of Angular CLI applications to the file system",
55
"properties": {
66
"baseHref": {
77
"type": "string",

src/engine/engine.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export async function run(dir: string, options: Schema, logger: logging.LoggerAp
1616

1717
await fse.copy(dir, options.targetDir)
1818

19-
logger.info('🚀 Successfully published via ngx-deploy-starter! Have a nice day!');
19+
logger.info('🚀 Successfully published via @angular-schule/ngx-deploy-starter! Have a nice day!');
2020
}
2121
catch (error) {
2222
logger.error('❌ An error occurred!');

src/ng-add.spec.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ const initialAngularJson = `{
170170
}
171171
},
172172
\"deploy\": {
173-
\"builder\": \"ngx-deploy-starter:deploy\",
173+
\"builder\": \"@angular-schule/ngx-deploy-starter:deploy\",
174174
\"options\": {}
175175
}
176176
}
@@ -202,7 +202,7 @@ const overwriteAngularJson = `{
202202
}
203203
},
204204
\"deploy\": {
205-
\"builder\": \"ngx-deploy-starter:deploy\",
205+
\"builder\": \"@angular-schule/ngx-deploy-starter:deploy\",
206206
\"options\": {}
207207
}
208208
}
@@ -234,7 +234,7 @@ const projectAngularJson = `{
234234
}
235235
},
236236
\"deploy\": {
237-
\"builder\": \"ngx-deploy-starter:deploy\",
237+
\"builder\": \"@angular-schule/ngx-deploy-starter:deploy\",
238238
\"options\": {}
239239
}
240240
}

src/ng-add.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ export const ngAdd = ({ project: DeployOptions }) => (
7979
}
8080

8181
project.architect['deploy'] = {
82-
builder: 'ngx-deploy-starter:deploy',
82+
builder: '@angular-schule/ngx-deploy-starter:deploy',
8383
options: {}
8484
};
8585

src/package-lock.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
2-
"name": "ngx-deploy-starter",
2+
"name": "@angular-schule/ngx-deploy-starter",
33
"version": "0.0.1",
4-
"description": "Deployment from the Angular CLI to the file system. This is a sample project that helps you to implement your own deployment builder (ng deploy) for the Angular CLI.",
4+
"description": "Deployment from the Angular CLI to the file system. This is a sample project that helps you to implement your own deployment builder (`ng deploy`) for the Angular CLI.",
55
"main": "index.js",
66
"scripts": {
77
"build": "rimraf dist && json2ts deploy/schema.json > deploy/schema.d.ts && tsc && copyfiles README.md builders.json collection.json package.json ngx-deploy-starter deploy/schema.json dist",

0 commit comments

Comments
 (0)