Skip to content

Commit 7e8df46

Browse files
authored
Merge pull request #10 from savi-lang/pull-from-base/c0ece23
Pull latest from savi-lang/base-standard-library
2 parents b96f14c + c0ece23 commit 7e8df46

File tree

4 files changed

+105
-3
lines changed

4 files changed

+105
-3
lines changed

.github/workflows/library-check.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ jobs:
3434
shell: ${{ matrix.shell }}
3535
steps:
3636
- uses: actions/checkout@v2
37-
- uses: savi-lang/action-install@v1.1.0
37+
- uses: savi-lang/action-install@v1
3838
- run: savi deps update --for spec
3939
- run: savi run spec ${{ runner.os == 'Windows' && '--cross-compile=x86_64-unknown-windows-msvc' || '' }}
4040

@@ -44,7 +44,7 @@ jobs:
4444
runs-on: ubuntu-latest
4545
steps:
4646
- uses: actions/checkout@v2
47-
- uses: savi-lang/action-install@v1.0.0
47+
- uses: savi-lang/action-install@v1
4848
- run: savi format --check
4949

5050
##

.github/workflows/library-deps-update.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ jobs:
2121
runs-on: ubuntu-latest
2222
steps:
2323
- uses: actions/checkout@v3
24-
- uses: savi-lang/action-install@v1.0.0
24+
- uses: savi-lang/action-install@v1
2525
- run: savi deps update --for spec
2626
- uses: peter-evans/create-pull-request@v4
2727
with:
Lines changed: 62 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,62 @@
1+
# NOTE: This file comes from `savi-lang/base-standard-library`
2+
#
3+
# This workflow is responsible for automating the creation of a new release.
4+
# As an input, the workflow takes a version tag to apply to the latest commit.
5+
# The version tag name will also be the release's name in GitHub.
6+
# Release notes will auto-generated by GitHub based on Pull Requests history.
7+
#
8+
# With some minor modification (see comments in the job definition below),
9+
# this workflow can also build release binaries for all supported platforms,
10+
# and package them up as tarballs attached as assets to the release in GitHub.
11+
# This is not relevant for all libraries, because many libraries do not have
12+
# any executable binary that is relevant to build, so it is disabled by default,
13+
# but for those libraries that have one or more application binaries to build,
14+
# all you need to do is specify the binary manifest's name and enable that step.
15+
#
16+
# The workflow is triggered by workflow dispatch, which means to run it you
17+
# need to press the "Run Workflow" button on the Actions page for this workflow,
18+
# then enter the required inputs when prompted to do so.
19+
# It can also be triggered via the GitHub API if desired.
20+
21+
name: library-release
22+
23+
on:
24+
pull_request: # (only to verify that the release build is working in PRs)
25+
workflow_dispatch:
26+
inputs:
27+
version-tag:
28+
description: |
29+
The name of the version to release (e.g. `v1.2.3` or `v0.20220131.0`).
30+
required: true
31+
32+
jobs:
33+
all:
34+
runs-on: ubuntu-latest
35+
steps:
36+
- uses: actions/checkout@v2
37+
- uses: savi-lang/action-install@v1
38+
39+
- uses: savi-lang/action-build-release@v1
40+
# Remove the following `if: false` line and replace all occurrences of
41+
# `my-app` placeholder with your application's bin manifest name
42+
# to enable building release binaries for your application.
43+
if: false
44+
id: my-app
45+
with:
46+
manifest-name: my-app
47+
tarball-name: my-app-${{ github.event.inputs.version-tag }}
48+
all-platforms: true
49+
macosx-accept-license: true
50+
windows-accept-license: true
51+
52+
- uses: softprops/action-gh-release@v1
53+
if: ${{ github.event.inputs.version-tag != '' }}
54+
with:
55+
tag_name: ${{ github.event.inputs.version-tag }}
56+
generate_release_notes: true
57+
token: ${{ secrets.BOT_GITHUB_TOKEN }} # (allows triggering workflows)
58+
59+
# Uncomment the following lines to upload release binaries.
60+
# fail_on_unmatched_files: true
61+
# files: |
62+
# ${{ steps.my-app.outputs.tarball-directory }}/*

CONTRIBUTING.md

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
# Contributing
2+
3+
Thanks for your interest in this project!
4+
5+
Here's some helpful context and guidance for how to contribute.
6+
7+
## Questions & Discussion
8+
9+
If you want to talk about this project, please reach out to the maintainers in [the Zulip chat server for Savi](https://savi.zulipchat.com/).
10+
11+
That's the best forum for any questions you might have or points you may want to raise for discussion. The people in our chat are open and friendly, and we welcome good faith, relevant discussions of all kinds.
12+
13+
## Bug Reports & Feature Requests
14+
15+
First, search [the issue tracker](../../issues) to check for any similar ticket relevant to your bug or feature idea that already exists. If it does, prefer adding a comment to that ticket. Otherwise, go ahead and [create a new ticket](../../issues/new/choose)!
16+
17+
Please ensure that your bug report or idea is clear and actionable. It should be a ticket about improving the project, which can be closed after the improvement is made (or if we decide not to make that improvement).
18+
19+
Issue tickets are not for general comments about the project, questions for personal learning, or open-ended discussions. Please use [the Zulip chat server for Savi](https://savi.zulipchat.com/) instead, where those kinds of discussions are welcome.
20+
21+
## Code Improvements
22+
23+
To make code improvements, please follow the standard [GitHub flow for pull requests](https://docs.github.com/en/get-started/quickstart/github-flow), using a short-lived feature branch.
24+
25+
If you have commit access to the repository, it's okay to create feature branches on the main repository. Otherwise, everyone is able to create feature branches on their personal fork.
26+
27+
We want to keep code changes easy to review, easy to understand in the commit history, and easy to revert if needed. In pursuit of this, please keep pull requests small and focused on one core idea. Use descriptive commit messages that will be easy for someone to understand when they're looking through the commit history years later. If your branch contains a lot of unfocused commits, please squash them into one or more meaningful commits before merging.
28+
29+
Small investments of time on your part don't need any coordination ahead of time, but if you're going to invest a lot of time in making large changes, it's a good idea to confirm ahead of time that your changes will be desirable to the maintainers to merge. Try sharing your proposed approach in a relevant issue ticket or in [the Zulip chat server for Savi](https://savi.zulipchat.com/) to make sure you're using an approach that's going to be acceptable for the project.
30+
31+
## Creating a Release
32+
33+
If you're a regular contributor here, you may have commit access to this repository. If so, feel free to create a new release at any time one is desired, as long as the CI workflows are passing on the main branch.
34+
35+
To create a release, go to [the `library-release` CI workflow in GitHub Actions](../../actions/workflows/library-release.yaml) and click the "Run Workflow" button there. When prompted, enter a version tag name for the release. Here's how to name the tag:
36+
37+
- for stable projects (`v1.0.0` and higher) use [semantic versioning](https://semver.org/), including a `v` prefix before the number segments.
38+
- for pre-stable projects use a tag name like `v0.YYYYMMDD.N`, where `YYYYMMDD` is the current date in ISO-8601 format, and `N` is the lowest number released on that date, starting at zero and moving up with each subsequent release on the same day.
39+
40+
If you don't have access to create a release yourself, reach out to one of the maintainers in [the Zulip chat server for Savi](https://savi.zulipchat.com/) or in an issue ticket or pull request that was recently closed that includes the change you want to release. One of us can help get it released soon.

0 commit comments

Comments
 (0)