🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more →
Socket
Sign inDemoInstall
Socket

angular-cli-ghpages

Package Overview
Dependencies
Maintainers
2
Versions
43
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

angular-cli-ghpages - npm Package Compare versions

Comparing version

to
2.0.0

5

deploy/schema.json

@@ -74,2 +74,7 @@ {

},
"add": {
"type": "boolean",
"description": "Only add, and never remove existing files from the GitHub pages branch.",
"default": false
},
"dir": {

@@ -76,0 +81,0 @@ "type": "string",

1

engine/defaults.js

@@ -15,2 +15,3 @@ "use strict";

cname: undefined,
add: false,
dryRun: false,

@@ -17,0 +18,0 @@ remote: 'origin',

3

engine/engine.js

@@ -236,3 +236,4 @@ "use strict";

nojekyll: options.nojekyll ? 'a .nojekyll file will be created' : 'a .nojekyll file will NOT be created',
cname: options.cname ? `a CNAME file with the content '${options.cname}' will be created` : 'a CNAME file will NOT be created'
cname: options.cname ? `a CNAME file with the content '${options.cname}' will be created` : 'a CNAME file will NOT be created',
add: options.add ? 'all files will be added to the branch. Existing files will not be removed' : 'existing files will be removed from the branch before adding the new ones',
}, null, ' '));

@@ -239,0 +240,0 @@ return;

{
"name": "angular-cli-ghpages",
"version": "2.0.0-beta.2",
"version": "2.0.0",
"description": "Deploy your Angular app to GitHub Pages or Cloudflare Pages directly from the Angular CLI (ng deploy)",

@@ -58,5 +58,5 @@ "main": "index.js",

"devDependencies": {
"@angular-devkit/architect": "~0.1700.0",
"@angular-devkit/core": "^17.0.0",
"@angular-devkit/schematics": "^17.0.0",
"@angular-devkit/architect": "~0.1800.0",
"@angular-devkit/core": "^18.0.0",
"@angular-devkit/schematics": "^18.0.0",
"@types/fs-extra": "^11.0.4",

@@ -73,5 +73,5 @@ "@types/jest": "^29.5.11",

"dependencies": {
"@angular-devkit/architect": "~0.1700.0",
"@angular-devkit/core": "^17.0.0",
"@angular-devkit/schematics": "^17.0.0",
"@angular-devkit/architect": "~0.1800.0",
"@angular-devkit/core": "^18.0.0",
"@angular-devkit/schematics": "^18.0.0",
"commander": "^3.0.0-0",

@@ -78,0 +78,0 @@ "fs-extra": "^11.2.0",

@@ -30,2 +30,3 @@ # angular-cli-ghpages

- [--cname](#cname)
- [--add](#add)
- [--dry-run](#dry-run)

@@ -81,5 +82,5 @@ 7. [📁 Configuration File](#configuration-file)

For your convenience, you can also use `prerenderTarget` (which adds the suffix `:prerender:production`).
There is no support for `universalBuildTarget` or `serverTarget` because Github Pages only supports static assets and no Server-Side Rendering!
There is no support for `universalBuildTarget` or `serverTarget` because GitHub Pages only supports static assets and no Server-Side Rendering!
We will then try to deploy the `dist/test/browser` folder to Github Pages.
We will then try to deploy the `dist/test/browser` folder to GitHub Pages.
If this is not the folder that you want to serve, you should explicitly specify the directory with the `--dir` option:

@@ -116,3 +117,3 @@

2. By default the Angular CLI initializes a Git repository for you.
2. By default, the Angular CLI initializes a Git repository for you.
To add a new remote for GitHub, use the `git remote add` command:

@@ -173,4 +174,4 @@

If you run this command from a CI/CD environment, the deployment will most likely not work out of the box.
For security reasons, those environments usually have read-only privileges or you haven't set up Git correctly.
Therefore you should take a look at ["personal access tokens" `GH_TOKEN`](https://help.github.com/articles/creating-an-access-token-for-command-line-use/) (which works everywhere) and the ["installation access token" `GITHUB_TOKEN`](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/authenticating-with-the-github_token) (which is exclusively provided by GitHub actions).
For security reasons, those environments usually have read-only privileges, or you haven't set up Git correctly.
Therefore, you should take a look at ["personal access tokens" `GH_TOKEN`](https://help.github.com/articles/creating-an-access-token-for-command-line-use/) (which works everywhere) and the ["installation access token" `GITHUB_TOKEN`](https://help.github.com/en/actions/automating-your-workflow-with-github-actions/authenticating-with-the-github_token) (which is exclusively provided by GitHub actions).
In short: a token replaces username and password and is a safer choice because a token can be revoked at any time.

@@ -208,3 +209,3 @@

Specifies the base URL for the application being built.
Specify the base URL for the application being built.
Same as `ng build --base-href=/XXX/`

@@ -274,3 +275,3 @@

Skip build process during deployment.
Skip the build process during deployment.
This can be used when you are sure that you haven't changed anything and want to deploy with the latest artifact.

@@ -289,3 +290,3 @@ This command causes the `--build-target` setting to have no effect.

and that you want to push changes to the `origin` remote.
If instead your files are not in a git repository, or if you want to push to another repository,
If instead, your files are not in a git repository, or if you want to push to another repository,
you can provide the repository URL in the `repo` option.

@@ -350,4 +351,5 @@

By default a `404.html` file is created, because this is the only known workaround to avoid 404 error messages on GitHub Pages.
For Cloudflare Pages we highly recommend to disable the `404.html` file by setting this switch to true! see [#178](https://github.com/angular-schule/angular-cli-ghpages/issues/178)
By default, a `404.html` file is created, because this is the only known workaround to avoid 404 error messages on GitHub Pages.
For Cloudflare Pages we highly recommend to disable the `404.html` file by setting this switch to true!
See [#178](https://github.com/angular-schule/angular-cli-ghpages/issues/178)

@@ -362,3 +364,3 @@ #### --no-nojekyll <a name="no-nojekyll"></a>

By default a `.nojekyll` file is created, because we assume you don't want to compile the build again with Jekyll.
By default, a `.nojekyll` file is created, because we assume you don't want to compile the build again with Jekyll.

@@ -382,2 +384,13 @@ **Explanation:**

#### --add <a name="add"></a>
- **optional**
- Default: `false` (boolean) – The existing files will be removed from the branch you'll be pushing to as expected.
- Example:
- `ng deploy --add=true`
If is set to `true`, it will only add, and never remove existing files.
By default, existing files in the target branch are removed before adding the ones.
[More information](https://www.npmjs.com/package/gh-pages#optionsadd).
#### --dir <a name="dir"></a>

@@ -452,3 +465,3 @@

We have seen `angular-cli-ghpages` running on various environments, like Travis CI, CircleCi or Github Actions.
We have seen `angular-cli-ghpages` running on various environments, like Travis CI, CircleCi or GitHub Actions.
Please share your knowledge by writing an article about how to set up the deployment.

@@ -455,0 +468,0 @@

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet