@sentry/craft 3.0.0 → 3.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +22 -111
- package/dist/craft +4129 -7073
- package/package.json +5 -5
package/README.md
CHANGED
|
@@ -11,38 +11,19 @@
|
|
|
11
11
|
|
|
12
12
|
Craft is a command line tool that helps automate and pipeline package releases. It enforces a specific workflow for managing release branches, changelogs, and artifact publishing.
|
|
13
13
|
|
|
14
|
-
📚 **[Full Documentation](https://
|
|
14
|
+
📚 **[Full Documentation](https://craft.sentry.dev/)**
|
|
15
15
|
|
|
16
16
|
## Quick Start
|
|
17
17
|
|
|
18
18
|
### Installation
|
|
19
19
|
|
|
20
|
-
Download a standalone executable for your OS and architecture from the
|
|
21
|
-
[latest release](https://github.com/getsentry/craft/releases/latest), or install
|
|
22
|
-
the portable JavaScript package via npm. Standalone executables embed Node;
|
|
23
|
-
npm installation requires Node. The legacy `craft` asset remains a JavaScript bundle.
|
|
24
|
-
|
|
25
|
-
```shell
|
|
26
|
-
npm install -g @sentry/craft
|
|
27
|
-
```
|
|
28
|
-
|
|
29
|
-
Homebrew installation will be available after the first stable release publishing
|
|
30
|
-
these binaries and its formula:
|
|
31
|
-
|
|
32
|
-
```shell
|
|
33
|
-
brew install getsentry/tools/craft
|
|
34
|
-
```
|
|
35
|
-
|
|
36
|
-
Once the first native release and installer website are published:
|
|
37
|
-
|
|
38
20
|
```shell
|
|
39
21
|
curl -fsSL https://craft.sentry.dev/install | bash
|
|
40
22
|
```
|
|
41
23
|
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
and running the script locally.
|
|
24
|
+
Homebrew (`brew install getsentry/tools/craft`), standalone binaries, and npm
|
|
25
|
+
(`npm install -g @sentry/craft`) are also available. See
|
|
26
|
+
[Installation](https://craft.sentry.dev/installation/).
|
|
46
27
|
|
|
47
28
|
### Usage
|
|
48
29
|
|
|
@@ -57,22 +38,24 @@ craft prepare 1.2.3
|
|
|
57
38
|
craft publish 1.2.3
|
|
58
39
|
```
|
|
59
40
|
|
|
41
|
+
See the [Quick Start](https://craft.sentry.dev/getting-started/) to set up a project.
|
|
42
|
+
|
|
60
43
|
## Features
|
|
61
44
|
|
|
62
|
-
- **Auto Versioning** -
|
|
63
|
-
- **Multiple Targets** - Publish to GitHub,
|
|
64
|
-
- **Changelog Management** - Auto-generate changelogs from
|
|
65
|
-
- **AI Changelog Summaries** -
|
|
66
|
-
- **
|
|
67
|
-
- **CI Integration** - Wait for CI to pass, download artifacts, and publish
|
|
68
|
-
- **GitHub Actions** -
|
|
45
|
+
- **[Auto Versioning](https://craft.sentry.dev/versioning/)** - Determine version bumps from conventional commits, or use CalVer
|
|
46
|
+
- **[Multiple Targets](https://craft.sentry.dev/targets/)** - Publish to GitHub, npm, PyPI, Docker, crates.io, NuGet, and more
|
|
47
|
+
- **[Changelog Management](https://craft.sentry.dev/changelogs/)** - Auto-generate changelogs from pull requests or validate manual entries
|
|
48
|
+
- **[AI Changelog Summaries](https://craft.sentry.dev/ai-summaries/)** - Optional release, category, and scope summaries on top of generated changelogs
|
|
49
|
+
- **[Monorepo Support](https://craft.sentry.dev/workspaces/)** - Release independently versioned products from one repository with release workspaces
|
|
50
|
+
- **[CI Integration](https://craft.sentry.dev/release-workflow/)** - Wait for CI to pass, download artifacts, and publish
|
|
51
|
+
- **[GitHub Actions](https://craft.sentry.dev/github-actions/)** - Reusable workflows for releases and changelog previews
|
|
69
52
|
|
|
70
53
|
## Configuration
|
|
71
54
|
|
|
72
55
|
Create a `.craft.yml` in your project root:
|
|
73
56
|
|
|
74
57
|
```yaml
|
|
75
|
-
minVersion: '2.
|
|
58
|
+
minVersion: '2.21.0'
|
|
76
59
|
changelog:
|
|
77
60
|
policy: auto
|
|
78
61
|
targets:
|
|
@@ -81,39 +64,10 @@ targets:
|
|
|
81
64
|
access: public
|
|
82
65
|
```
|
|
83
66
|
|
|
84
|
-
See the [configuration reference](https://
|
|
85
|
-
|
|
86
|
-
## Supported Targets
|
|
87
|
-
|
|
88
|
-
| Target | Description |
|
|
89
|
-
| ------------------ | ------------------------------------- |
|
|
90
|
-
| `github` | GitHub releases and tags |
|
|
91
|
-
| `npm` | NPM registry (with workspace support) |
|
|
92
|
-
| `pypi` | Python Package Index |
|
|
93
|
-
| `crates` | Rust crates.io |
|
|
94
|
-
| `nuget` | .NET NuGet |
|
|
95
|
-
| `docker` | Docker registries |
|
|
96
|
-
| `brew` | Homebrew formulas |
|
|
97
|
-
| `gcs` | Google Cloud Storage |
|
|
98
|
-
| `gh-pages` | GitHub Pages |
|
|
99
|
-
| `cocoapods` | CocoaPods |
|
|
100
|
-
| `gem` | RubyGems |
|
|
101
|
-
| `maven` | Maven Central |
|
|
102
|
-
| `hex` | Elixir Hex |
|
|
103
|
-
| `pub-dev` | Dart/Flutter pub.dev |
|
|
104
|
-
| `aws-lambda-layer` | AWS Lambda layers |
|
|
105
|
-
| `powershell` | PowerShell Gallery |
|
|
106
|
-
|
|
107
|
-
See the [targets documentation](https://getsentry.github.io/craft/targets/) for configuration details.
|
|
67
|
+
See the [configuration reference](https://craft.sentry.dev/configuration/) for all options.
|
|
108
68
|
|
|
109
69
|
## GitHub Actions
|
|
110
70
|
|
|
111
|
-
Craft provides GitHub Actions for automating releases and previewing changelog entries.
|
|
112
|
-
|
|
113
|
-
### Prepare Release Action
|
|
114
|
-
|
|
115
|
-
Automates the `craft prepare` workflow in GitHub Actions:
|
|
116
|
-
|
|
117
71
|
```yaml
|
|
118
72
|
name: Release
|
|
119
73
|
on:
|
|
@@ -125,59 +79,16 @@ on:
|
|
|
125
79
|
|
|
126
80
|
jobs:
|
|
127
81
|
release:
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
- uses: getsentry/craft@v2
|
|
134
|
-
with:
|
|
135
|
-
version: ${{ github.event.inputs.version }}
|
|
136
|
-
env:
|
|
137
|
-
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
|
138
|
-
```
|
|
139
|
-
|
|
140
|
-
**Inputs:**
|
|
141
|
-
|
|
142
|
-
| Input | Description | Default |
|
|
143
|
-
| --------------- | --------------------------------------------------------------------------------------------- | ------------------------------------ |
|
|
144
|
-
| `version` | Version to release (semver, "auto", "major", "minor", "patch") | Uses `versioning.policy` from config |
|
|
145
|
-
| `merge_target` | Target branch to merge into | Default branch |
|
|
146
|
-
| `force` | Force release even with blockers | `false` |
|
|
147
|
-
| `blocker_label` | Label that blocks releases | `release-blocker` |
|
|
148
|
-
| `publish_repo` | Repository for publish issues. Use `"self"` to create issues in the source repository itself. | `{owner}/publish` |
|
|
149
|
-
|
|
150
|
-
**Outputs:**
|
|
151
|
-
|
|
152
|
-
| Output | Description |
|
|
153
|
-
| ----------- | ------------------------------------ |
|
|
154
|
-
| `version` | The resolved version being released |
|
|
155
|
-
| `branch` | The release branch name |
|
|
156
|
-
| `sha` | The commit SHA on the release branch |
|
|
157
|
-
| `changelog` | The changelog for this release |
|
|
158
|
-
|
|
159
|
-
### Changelog Preview (Reusable Workflow)
|
|
160
|
-
|
|
161
|
-
Posts a preview comment on PRs showing how they'll appear in the changelog:
|
|
162
|
-
|
|
163
|
-
```yaml
|
|
164
|
-
name: Changelog Preview
|
|
165
|
-
on:
|
|
166
|
-
pull_request:
|
|
167
|
-
types: [opened, synchronize, reopened, edited, labeled]
|
|
168
|
-
|
|
169
|
-
jobs:
|
|
170
|
-
changelog-preview:
|
|
171
|
-
uses: getsentry/craft/.github/workflows/changelog-preview.yml@v2
|
|
82
|
+
permissions:
|
|
83
|
+
contents: write
|
|
84
|
+
uses: getsentry/craft/.github/workflows/release.yml@v2
|
|
85
|
+
with:
|
|
86
|
+
version: ${{ inputs.version }}
|
|
172
87
|
secrets: inherit
|
|
173
88
|
```
|
|
174
89
|
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
- Generate the upcoming changelog including the PR's changes
|
|
178
|
-
- Highlight entries from the PR using blockquote style (left border)
|
|
179
|
-
- Post a comment on the PR with the preview
|
|
180
|
-
- Automatically update when you update the PR (push, edit title/description, or change labels)
|
|
90
|
+
See [GitHub Actions](https://craft.sentry.dev/github-actions/) for all inputs,
|
|
91
|
+
the composite action, and the changelog preview workflow.
|
|
181
92
|
|
|
182
93
|
## Contributing
|
|
183
94
|
|