-
-
Notifications
You must be signed in to change notification settings - Fork 87
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #217 from satanTime/issues/export-all
Issues/export all
- Loading branch information
Showing
100 changed files
with
15,062 additions
and
9,511 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 |
---|---|---|
|
@@ -9,3 +9,4 @@ | |
/e2e/a11/node_modules | ||
/node_modules | ||
/test-reports | ||
/tmp |
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,5 +1,7 @@ | ||
.DS_Store | ||
.env | ||
.idea | ||
dist | ||
node_modules | ||
test-reports | ||
/dist | ||
/node_modules | ||
/test-reports | ||
/tmp |
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,40 @@ | ||
const path = require('path'); | ||
|
||
module.exports = { | ||
'*': filenames => { | ||
const commands = []; | ||
const cwd = process.cwd(); | ||
const files = filenames | ||
.filter(file => !file.match(/\.(ts)$/i)) | ||
.map(file => path.relative(cwd, file)) | ||
.map(file => `'${file}'`); | ||
if (files.length === 0) { | ||
return []; | ||
} | ||
|
||
commands.push(`prettier --write ${files.join(' ')}`); | ||
|
||
return commands; | ||
}, | ||
'*.ts': filenames => { | ||
const commands = []; | ||
const cwd = process.cwd(); | ||
const files = filenames.map(file => path.relative(cwd, file)).map(file => `'${file}'`); | ||
if (files.length === 0) { | ||
return []; | ||
} | ||
|
||
const filesForLint = filenames | ||
.map(file => path.relative(cwd, file)) | ||
.filter(file => !file.match(/^e2e\//i)) | ||
.filter(file => !file.match(/^test\//i)) | ||
.map(file => `'${file}'`); | ||
|
||
if (filesForLint.length) { | ||
commands.push(`npm run lint -- --fix --force ${filesForLint.join(' ')}`); | ||
} | ||
commands.push(`prettier --write ${files.join(' ')}`); | ||
|
||
return commands; | ||
}, | ||
}; |
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,24 @@ | ||
release: | ||
branches: | ||
- master | ||
plugins: | ||
- '@semantic-release/commit-analyzer' | ||
- - '@semantic-release/exec' | ||
- prepareCmd: npm run lint && npm run test && npm run build | ||
- '@semantic-release/release-notes-generator' | ||
- - '@semantic-release/changelog' | ||
- changelogFile: CHANGELOG.md | ||
- - '@semantic-release/npm' | ||
- tarballDir: tmp | ||
npmPublish: false | ||
- - '@semantic-release/github' | ||
- assets: | ||
- tmp/*.tgz | ||
successComment: |- | ||
${nextRelease.version} has been released and contains a fix for the issue. | ||
Feel free to reopen the issue or to submit a new one if you meet any problems. | ||
failTitle: false | ||
failComment: false | ||
labels: false | ||
- - '@semantic-release/git' | ||
- message: "chore(release): ${nextRelease.version}\n\n${nextRelease.notes}" |
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,36 @@ | ||
# How to contribute to ngMocks | ||
|
||
The best way would be to discuss an issue or an improvement first: | ||
|
||
- [ask a question on gitter](https://gitter.im/ng-mocks/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge) | ||
- [report it as an issue on github](https://github.com/ike18t/ng-mocks/issues) | ||
|
||
## How to release ngMocks | ||
|
||
It is possible on Unix based OS, Windows has not been supported. | ||
|
||
You need to create a `.env` file with the next content: | ||
|
||
```dotenv | ||
GH_TOKEN=<GITHUB_TOKEN> | ||
NPM_TOKEN=<NPM_TOKEN> | ||
GIT_AUTHOR_NAME=<YOUR_NAME> | ||
GIT_AUTHOR_EMAIL=<YOUR_EMAIL> | ||
GIT_COMMITTER_NAME=<YOUR_NAME> | ||
GIT_COMMITTER_EMAIL=<YOUR_EMAIL> | ||
``` | ||
|
||
An example of it is: | ||
|
||
```dotenv | ||
GH_TOKEN=123123123 | ||
NPM_TOKEN=123123123 | ||
GIT_AUTHOR_NAME=Best Coder | ||
[email protected] | ||
GIT_COMMITTER_NAME=Best Coder | ||
[email protected] | ||
``` | ||
|
||
After that you need to execute `npm run release`. | ||
|
||
Profit. |
Oops, something went wrong.