|
1 | 1 | # angular-cli-ghpages
|
2 | 2 |
|
3 | 3 | Angular CLI addon. Publish to any gh-pages branch on GitHub (or any other branch on any other remote).
|
4 |
| -This is __NOT__ [IgorMinar/angular-cli-github-pages](https://github.com/IgorMinar/angular-cli-github-pages). |
| 4 | +This is __NOT__ [IgorMinar/angular-cli-github-pages](https://github.com/IgorMinar/angular-cli-github-pages). Brought to you by the [angular2buch.de](https://angular2buch.de/) team! |
5 | 5 |
|
6 | 6 | ## WHY?
|
7 | 7 |
|
8 |
| -[IgorMinar/angular-cli-github-pages](https://github.com/IgorMinar/angular-cli-github-pages) is fixed to the `gh-pages` branch of the same repository. In my oponion it is also trying to do too much. |
9 |
| -In contrast to this, the [Angular2Buch/angular-cli-ghpages](https://github.com/Angular2Buch/angular-cli-ghpages) addon is much more simple. It pushes to any branch on any repository, by utilizing [tschaub/gh-pages](https://github.com/tschaub/gh-pages). Nothing more. |
10 |
| -This addon works great on Travis-CI. |
| 8 | +[IgorMinar/angular-cli-github-pages](https://github.com/IgorMinar/angular-cli-github-pages) is limited to the `gh-pages` branch of the same repository. |
| 9 | + |
| 10 | +In contrast to this, the [Angular2Buch/angular-cli-ghpages](https://github.com/Angular2Buch/angular-cli-ghpages) addon is able to push to any branch on any repository. It's build on top of [tschaub/gh-pages](https://github.com/tschaub/gh-pages). |
| 11 | + |
| 12 | +__This addon works great on [Travis-CI](https://travis-ci.org/).__ |
11 | 13 |
|
12 | 14 | ## Installation & Setup
|
13 | 15 |
|
@@ -35,14 +37,6 @@ ng build
|
35 | 37 | ng ghpages [OPTIONS]
|
36 | 38 | ```
|
37 | 39 |
|
38 |
| -The following command runs on our Travis-CI: |
39 |
| - |
40 |
| -```sh |
41 |
| -ng build --environment=production |
42 |
| -ng ghpages --repo=https://TheBuildbot: [email protected]/Angular2Buch/book-monkey2-public.git --name= "The Buildbot" [email protected] |
43 |
| -``` |
44 |
| - |
45 |
| - |
46 | 40 | ## Options
|
47 | 41 |
|
48 | 42 | #### <a id="repo">--repo</a>
|
@@ -84,9 +78,20 @@ If you are running the command in a repository without a `user.name` or `user.em
|
84 | 78 |
|
85 | 79 | Suppress logging. With silent `true` log messages are suppressed and error messages are sanitized.
|
86 | 80 |
|
87 |
| -> This option should be used if the repository URL or other information passed to git commands is sensitive and should not be logged. |
| 81 | +> This option should be used if the repository URL or other information passed to git commands is sensitive and should not be logged. By default the silent mode is enabled to avoid sensitive data exposure. |
| 82 | +
|
| 83 | + |
| 84 | +## Extra |
| 85 | + |
| 86 | +For your convenience, the addon will recognize the [environment variable](https://docs.travis-ci.com/user/environment-variables/#Defining-Variables-in-Repository-Settings) `REPO_USER_AND_PASS` and will replace this pattern in the `--repo` string. Please __do NOT disable the silent mode__ if you have credentials in the repository URL! |
88 | 87 |
|
| 88 | +In example, the following command runs [on our Travis-CI](https://travis-ci.org/Angular2Buch/book-monkey2): |
89 | 89 |
|
| 90 | +```sh |
| 91 | +ng build --environment=production |
| 92 | +ng ghpages --repo=https:// [email protected]/Angular2Buch/book-monkey2-public.git --name= "The Buildbot" [email protected] |
| 93 | +``` |
| 94 | +> REPO_USER_AND_PASS stores credentials in the format `username:password`. Special charcaters must be [percent-encoded](https://en.wikipedia.org/wiki/Percent-encoding). |
90 | 95 |
|
91 | 96 | ## License
|
92 | 97 | Code released under the [MIT license](https://opensource.org/licenses/MIT).
|
0 commit comments