Skip to content

Commit

Permalink
[Doc] Base documentation
Browse files Browse the repository at this point in the history
  • Loading branch information
jtouzy committed Dec 28, 2020
1 parent 4b4332e commit b2847ed
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 2 deletions.
51 changes: 50 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,51 @@
# ReleaseNoteNow
# Release Note Now

Automatic release note generator for GitHub projects.

## Install

Just install as NPM dependency.

```
npm install @pictarine/release-note-now --save
```

## Run

For easy access, add a script into your package.json :

```json
{
"scripts": {
"rn": "release-note-now"
}
}
```

Launch example :

```
npm run rn \
-- \
-t ${{ secrets.GITHUB_TOKEN }} \
-r Pictarine/my_ios_repo \
-v "xcconfig:Shared/Supporting Files/Main.xcconfig"
```

### Options

```
--help Show help [boolean]
-t, --token GitHub Token [required]
-r, --repo GitHub repository (owner/repo) [required]
-k, --keys [required] [default: "feat:Features,fix:Fixes"]
-v, --version [required]
```

> For the -k option, you can define any key+title that will be searched in commit list.
> - For example, "config:Configuration" will search every commit starting with "[Config]" (uppercased/lowercased), then print them in "Configuration" section in your release note.
> The -v option supports three types of versionning right now:
> - **xcconfig:<path_to_xcconfig>** : Search for an xcconfig file, then extract VERSION_NUMBER + BUILD_NUMBER to generate tag
> - **increment:<increment_count>** : The next tag will increment the last tag + your increment count
> - **package.json:<path_to_file>** : Take the version in package.json file
2 changes: 1 addition & 1 deletion index.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ module.exports = async({ token, repo, keys, versionType }) => {
const markdown = MarkdownGenerator.generate({
keys, owner, repo: repoName, oldTag: release.tag, newTag: version.tag, commits
})
// await git.createRelease({ name: version.name, tag: version.tag, markdown })
await git.createRelease({ name: version.name, tag: version.tag, markdown })
logger.success(`Release ${logger.bold(version.tag)} generated successfully.`)
} catch (error) {
logger.error(error)
Expand Down

0 comments on commit b2847ed

Please sign in to comment.