-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
init
- Loading branch information
Showing
24 changed files
with
4,663 additions
and
90 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
root = true | ||
|
||
[*] | ||
indent_style = space | ||
indent_size = 2 | ||
charset = utf-8 | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
/lib |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
{ | ||
"extends": [ | ||
"oclif", | ||
"oclif-typescript" | ||
] | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,104 +1,85 @@ | ||
# Logs | ||
logs | ||
*.log | ||
npm-debug.log* | ||
yarn-debug.log* | ||
yarn-error.log* | ||
lerna-debug.log* | ||
|
||
# Diagnostic reports (https://nodejs.org/api/report.html) | ||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json | ||
|
||
# Runtime data | ||
pids | ||
*.pid | ||
*.seed | ||
*.pid.lock | ||
|
||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
lib-cov | ||
|
||
# Coverage directory used by tools like istanbul | ||
coverage | ||
*.lcov | ||
|
||
# nyc test coverage | ||
.nyc_output | ||
|
||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) | ||
.grunt | ||
|
||
# Bower dependency directory (https://bower.io/) | ||
bower_components | ||
|
||
# node-waf configuration | ||
.lock-wscript | ||
|
||
# Comment in the public line in if your project uses Gatsby and *not* Next.js | ||
# Compiled binary addons (https://nodejs.org/api/addons.html) | ||
build/Release | ||
|
||
# Coverage directory used by tools like istanbul | ||
# Dependency directories | ||
node_modules/ | ||
jspm_packages/ | ||
|
||
# TypeScript v1 declaration files | ||
typings/ | ||
|
||
# TypeScript cache | ||
*.tsbuildinfo | ||
|
||
# Optional npm cache directory | ||
.npm | ||
|
||
# Optional eslint cache | ||
.eslintcache | ||
|
||
# Diagnostic reports (https://nodejs.org/api/report.html) | ||
# Directory for instrumented libs generated by jscoverage/JSCover | ||
# DynamoDB Local files | ||
# FuseBox cache | ||
# Gatsby files | ||
# Grunt intermediate storage (https://gruntjs.com/creating-plugins#storing-task-files) | ||
# Logs | ||
# Microbundle cache | ||
.rpt2_cache/ | ||
.rts2_cache_cjs/ | ||
.rts2_cache_es/ | ||
.rts2_cache_umd/ | ||
|
||
# Next.js build output | ||
# Nuxt.js build / generate output | ||
# Optional REPL history | ||
.node_repl_history | ||
|
||
# Optional eslint cache | ||
# Optional npm cache directory | ||
# Output of 'npm pack' | ||
*.tgz | ||
|
||
# Runtime data | ||
# Serverless directories | ||
# TernJS port file | ||
# TypeScript cache | ||
# TypeScript v1 declaration files | ||
# Yarn Integrity file | ||
.yarn-integrity | ||
|
||
# dotenv environment variables file | ||
.env | ||
.env.test | ||
|
||
# https://nextjs.org/blog/next-9-1#public-directory-support | ||
# node-waf configuration | ||
# nyc test coverage | ||
# parcel-bundler cache (https://parceljs.org/) | ||
# public | ||
# vuepress build output | ||
*-debug.log | ||
*-error.log | ||
*.lcov | ||
*.log | ||
*.pid | ||
*.pid.lock | ||
*.seed | ||
*.tgz | ||
*.tsbuildinfo | ||
.cache | ||
|
||
# Next.js build output | ||
.cache/ | ||
.dynamodb/ | ||
.env | ||
.env.test | ||
.eslintcache | ||
.fusebox/ | ||
.grunt | ||
.lock-wscript | ||
.next | ||
|
||
# Nuxt.js build / generate output | ||
.node_repl_history | ||
.npm | ||
.nuxt | ||
dist | ||
|
||
# Gatsby files | ||
.cache/ | ||
# Comment in the public line in if your project uses Gatsby and *not* Next.js | ||
# https://nextjs.org/blog/next-9-1#public-directory-support | ||
# public | ||
|
||
# vuepress build output | ||
.vuepress/dist | ||
|
||
# Serverless directories | ||
.nyc_output | ||
.rpt2_cache/ | ||
.rts2_cache_cjs/ | ||
.rts2_cache_es/ | ||
.rts2_cache_umd/ | ||
.serverless/ | ||
|
||
# FuseBox cache | ||
.fusebox/ | ||
|
||
# DynamoDB Local files | ||
.dynamodb/ | ||
|
||
# TernJS port file | ||
.tern-port | ||
.vuepress/dist | ||
.yarn-integrity | ||
/.nyc_output | ||
/dist | ||
/lib | ||
/tmp | ||
/yarn.lock | ||
bower_components | ||
build/Release | ||
coverage | ||
dist | ||
jspm_packages/ | ||
lerna-debug.log* | ||
lib-cov | ||
logs | ||
node_modules | ||
node_modules/ | ||
npm-debug.log* | ||
pids | ||
report.[0-9]*.[0-9]*.[0-9]*.[0-9]*.json | ||
typings/ | ||
yarn-debug.log* | ||
yarn-error.log* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
language: node_js | ||
node_js: | ||
- node | ||
|
||
cache: npm | ||
|
||
script: | ||
- npm run test-unit | ||
|
||
|
||
after_success: | ||
- ./node_modules/.bin/nyc report --reporter text-lcov > coverage.lcov | ||
- bash < (curl -s https://codecov.io/bash) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,107 @@ | ||
# private-git-packages | ||
private-git-packages | ||
==================== | ||
|
||
CLI allows dynamically inject secret variables for git dependencies in package.json. It gives protected way use git dependencies in package.json in CI/CD | ||
|
||
|
||
``` | ||
# ANY CI | ||
pgp change --username=BasicAuthUsername --password=BasicAuthPassword | ||
npm i | ||
pgp rollback | ||
``` | ||
|
||
``` | ||
# GITLAB CI | ||
pgp change --username=gitlab-ci-token --password=$CI_JOB_TOKEN | ||
npm i | ||
pgp rollback | ||
``` | ||
|
||
[![oclif](https://img.shields.io/badge/cli-oclif-brightgreen.svg)](https://oclif.io) | ||
[![Version](https://img.shields.io/npm/v/private-git-packages.svg)](https://npmjs.org/package/private-git-packages) | ||
[![Codecov](https://codecov.io/gh/vMReal/private-git-packages/branch/master/graph/badge.svg)](https://codecov.io/gh/vMReal/private-git-packages) | ||
[![Downloads/week](https://img.shields.io/npm/dw/private-git-packages.svg)](https://npmjs.org/package/private-git-packages) | ||
[![License](https://img.shields.io/npm/l/private-git-packages.svg)](https://github.com/vMReal/private-git-packages/blob/master/package.json) | ||
|
||
<!-- toc --> | ||
* [Usage](#usage) | ||
* [Commands](#commands) | ||
<!-- tocstop --> | ||
|
||
# Usage | ||
<!-- usage --> | ||
```sh-session | ||
$ npm install -g @vmreal/private-git-packages | ||
$ pgp COMMAND | ||
running command... | ||
$ pgp (-v|--version|version) | ||
@vmreal/private-git-packages/0.1.0 linux-x64 node-v8.10.0 | ||
$ pgp --help [COMMAND] | ||
USAGE | ||
$ pgp COMMAND | ||
... | ||
``` | ||
<!-- usagestop --> | ||
# Commands | ||
<!-- commands --> | ||
* [`pgp change [PATTERN]`](#pgp-change-pattern) | ||
* [`pgp help [COMMAND]`](#pgp-help-command) | ||
* [`pgp rollback`](#pgp-rollback) | ||
|
||
## `pgp change [PATTERN]` | ||
|
||
describe the command here | ||
|
||
``` | ||
USAGE | ||
$ pgp change [PATTERN] | ||
ARGUMENTS | ||
PATTERN Pattern for restricting selection. Any text or regular expression. | ||
OPTIONS | ||
-h, --help show CLI help | ||
-n, --filename=filename [default: package] custom name of package.json | ||
-p, --password=password (required) password -> https://[username]:[password]@your-git-host.com/... | ||
-r, --recursively Apply to all files (package) at any level of nesting | ||
-u, --username=username (required) username -> https://[username]:[password]@your-git-host.com/... | ||
``` | ||
|
||
_See code: [src/commands/change.ts](https://github.com/vMReal/private-git-packages/blob/v0.1.0/src/commands/change.ts)_ | ||
|
||
## `pgp help [COMMAND]` | ||
|
||
display help for pgp | ||
|
||
``` | ||
USAGE | ||
$ pgp help [COMMAND] | ||
ARGUMENTS | ||
COMMAND command to show help for | ||
OPTIONS | ||
--all see all commands in CLI | ||
``` | ||
|
||
_See code: [@oclif/plugin-help](https://github.com/oclif/plugin-help/blob/v2.2.3/src/commands/help.ts)_ | ||
|
||
## `pgp rollback` | ||
|
||
describe the command here | ||
|
||
``` | ||
USAGE | ||
$ pgp rollback | ||
OPTIONS | ||
-h, --help show CLI help | ||
-n, --filename=filename [default: package] custom name of package.json | ||
-r, --recursively Apply to all files (package) at any level of nesting | ||
``` | ||
|
||
_See code: [src/commands/rollback.ts](https://github.com/vMReal/private-git-packages/blob/v0.1.0/src/commands/rollback.ts)_ | ||
<!-- commandsstop --> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/usr/bin/env node | ||
|
||
require('@oclif/command').run() | ||
.then(require('@oclif/command/flush')) | ||
.catch(require('@oclif/errors/handle')) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
@echo off | ||
|
||
node "%~dp0\run" %* |
Oops, something went wrong.