Skip to content

Commit 2455563

Browse files
committed
Bump version to 0.1.0
1 parent ae3848a commit 2455563

File tree

10 files changed

+66
-108
lines changed

10 files changed

+66
-108
lines changed

.changelog/config.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
project_url = "https://github.com/anoma/nspec"
2-
heading = "# Change Log"
2+
heading = "---\nicon: octicons/log-16\nsocial:\n cards: false\nsearch:\n exclude: false\nlist_wikilinks: false\n---\n\n# Change Log"
33
change_template = "change_template.md"
44
wrap = 120 # better for MkDocs
55
bullet = "-"
Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
- Add changelog management system
2-
([\#209](https://github.com/anoma/nspec/pull/209))
1+
- [**#209**](https://github.com/anoma/nspec/pull/209): Add changelog management system
File renamed without changes.

.github/workflows/deploy.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ name: deploy
22
'on':
33
push:
44
branches:
5+
- main
56
- v*
67
env:
78
CI: true
@@ -118,7 +119,7 @@ jobs:
118119
uses: JamesIves/github-pages-deploy-action@v4.6.4
119120
with:
120121
folder: ${{ env.BRANCH_NAME }}
121-
target-folder: latest
122+
target-folder: ${{ env.BRANCH_NAME == 'main' && 'latest' || env.BRANCH_NAME }}
122123
token: ${{ secrets.GITHUB_TOKEN }}
123124
clean: false
124125
git-config-name: Anoma Research

.pre-commit-config.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ repos:
2525
entry: filenames must be lower
2626
language: fail
2727
files: '[^a-z0-9._/]'
28-
exclude: '.pre-commit.*|^overrides.*|^docs/(assets|images)/|^formal.*|.*Package.juvix.*|^\.github/.*|CITATION|LICENSE|Makefile|README\.md|VERSION'
28+
exclude: '.pre-commit.*|^overrides.*|^docs/(assets|images)/|^formal.*|.*Package.juvix.*|^\.github/.*|CITATION|LICENSE|Makefile|README\.md|VERSION|.changelog/.*'
2929
- repo: https://github.com/jumanjihouse/pre-commit-hooks
3030
rev: 3.0.0
3131
hooks:

Makefile

Lines changed: 0 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
PORT?=8000
2-
VERSION?=$(shell cat VERSION)
32
PIP?=pip3
43

54
PWD=$(CURDIR)
@@ -43,42 +42,6 @@ test-build:
4342
art.bib:
4443
@curl -s -o docs/references/art.bib https://art.anoma.net/art.bib || echo "[!] Failed to download art.bib"
4544

46-
.PHONY: serve
47-
serve:
48-
mkdocs serve --dev-addr localhost:${PORT} --config-file ${MKDOCSCONFIG} ${MKDOCSFLAGS}
49-
50-
.PHONY : mike
51-
mike:
52-
@git fetch --all
53-
@git checkout gh-pages
54-
@git pull origin gh-pages --rebase
55-
@git checkout ${GITBRANCH}
56-
mike deploy ${VERSION} ${MIKEFLAGS} -t ${VERSION}
57-
58-
.PHONY: mike-serve
59-
mike-serve: docs
60-
mike serve --dev-addr localhost:${PORT} --config-file ${MKDOCSCONFIG}
61-
62-
.PHONY: delete-alias
63-
delete-alias:
64-
mike delete ${VERSION} ${MIKEFLAGS} > /dev/null 2>&1 || true
65-
66-
.PHONY: deploy
67-
deploy:
68-
${MAKE} delete-alias
69-
${MAKE} mike
70-
DEFAULTVERSION=$(shell cat VERSION); \
71-
if [ "${VERSION}" = "${DEFAULTVERSION}" ]; then \
72-
mike set-default ${MIKEFLAGS} ${DEFAULTVERSION}; \
73-
mike alias ${VERSION} latest -u ${MIKEFLAGS}; \
74-
fi; \
75-
git tag -d ${VERSION} > /dev/null 2>&1 || true; \
76-
git tag -a ${VERSION} -m "Release ${VERSION}"
77-
78-
install:
79-
@echo "[!] Use a Python virtual environment if you are not using one."
80-
${PIP} install -r requirements.txt
81-
8245
.PHONY : pre-commit
8346
pre-commit :
8447
@pre-commit run --all-files

VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
v2
1+
v0.1.0

docs/changelog.md

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
---
2+
icon: octicons/log-16
3+
social:
4+
cards: false
5+
search:
6+
exclude: false
7+
list_wikilinks: false
8+
---
9+
110
# Change Log
211

312
## v0.1.0
@@ -34,7 +43,6 @@ project per version, with better documentation and descriptions of the changes.
3443

3544
### BUG FIXES
3645

37-
3846
- [Repository maintenance and CI](.)
3947
- [**#4**](https://github.com/anoma/nspec/pull/4): Fix mike
4048
- [**#9**](https://github.com/anoma/nspec/pull/9): Add batch of fixes

docs/tutorial/branch.md

Lines changed: 50 additions & 63 deletions
Original file line numberDiff line numberDiff line change
@@ -8,75 +8,55 @@ tags:
88
# Git branching strategy
99

1010
The general workflow is to branch off from the latest version's branch, perform
11-
your changes, open a pull request, and merge your updates. An open pull request
12-
can finalise a version, or patch it with updates.
11+
your changes, open a pull request, and merge your updates.
1312

1413
## Branching strategy
1514

16-
For new versions, branch off from the latest version. This is usually done by
17-
maintainers. Call the branch as `vX`, where `X` is the new version number,
18-
the successor of the latest version. To find the latest version, check the
19-
`VERSION` file in the repository root. For example, if the latest version is
20-
`v1`, the new version branch will be `v2`, and the git graph will look like:
15+
### For changes to the latest version
16+
17+
For changes to the latest version, branch off from `main`. Name your branch by
18+
prefixing your name and an issue identifier, like `your-name/issue-identifier`.
19+
20+
```bash
21+
git checkout main
22+
git checkout -b your-name/issue-identifier
23+
```
24+
25+
### For changes to older published versions
26+
27+
For patching older versions, branch off from the specific version branch.
28+
Published versions follow the pattern `vX`, where `X` is the version number.
29+
For example, say the latest version is `v0.1.0`.
30+
31+
```bash
32+
git checkout v0.1.0
33+
```
34+
35+
Name your branch by prefixing your name and an patch topic, like
36+
`your-name/patch-topic`.
37+
38+
```bash
39+
git checkout -b your-name/patch-topic
40+
```
41+
42+
The git graph will look like:
2143

2244
```mermaid
2345
%%{init: { 'theme': 'neutral' } }%%
2446
gitGraph:
2547
commit
26-
branch v1
27-
checkout v1
48+
branch vX
49+
checkout vX
2850
commit
2951
branch your-name/issue-identifier
3052
checkout your-name/issue-identifier
3153
commit
32-
checkout v1
54+
checkout vX
3355
merge your-name/issue-identifier
34-
commit
35-
commit tag: "v1"
36-
branch v2
37-
checkout v2
38-
commit
39-
commit id:"still in development"
4056
```
4157

42-
!!! info
43-
44-
The branch `vX` is the base branch for all new features and patches for the
45-
version `X`. That means that, even when there are new versions, the branch `vX`
46-
can still be used for patches and minor updates to the version `X`.
47-
48-
49-
## Merging finalised versions
50-
51-
2. To merge a finalised version:
52-
53-
- Open a pull request against the version in development.
54-
- Pass all CI checks.
55-
- Tag it with the `vX` label.
56-
- Merge the pull request.
57-
58-
### Adding new features to the current version
59-
60-
For patches or minor updates, again, branch off from the latest version. Name
61-
your branch prefixing your name and an issue identifier, like
62-
`your-name/issue-identifier`. Short descriptive labels are recommended, like
63-
`fix-typo`, or `new-solver-engine`. So, the steps are:
64-
65-
1. **Fetch the latest changes**:
66-
```bash
67-
git fetch --all
68-
```
69-
2. **Create a new branch**:
70-
```bash
71-
git checkout vX # Replace vX with the current version
72-
git checkout -b your-name/issue-identifier
73-
```
74-
3. Open a pull request against the version in development. If you are using
75-
`gh`, after pushing your changes, you can create a pull request with:
76-
77-
```bash
78-
gh pr create
79-
```
58+
So, if your PR is merged, the changes will be incorporated into the version
59+
branch and on the website.
8060

8161
### Rebasing your work
8262

@@ -94,34 +74,41 @@ the following.
9474
- Initiate the rebase onto the target branch:
9575

9676
```bash
97-
git pull origin vX --rebase
77+
git pull origin main --rebase
9878
```
9979

100-
Or merge the changes from the base branch:
80+
Or merge the changes from the base branch which is convenient most of the
81+
time:
10182

10283
```bash
103-
git merge vX
84+
git merge main
10485
```
10586

10687
#### Resolve conflicts
10788

10889
- Git will pause for conflict resolution.
10990
- After resolving each conflict:
110-
```bash
111-
git rebase --continue
112-
```
91+
92+
```bash
93+
git rebase --continue
94+
```
95+
11396
- To stop the rebase process:
114-
```bash
115-
git rebase --abort
116-
```
97+
98+
```bash
99+
git rebase --abort
100+
```
117101

118102
#### Push your changes
119103

120104
- Once rebase is complete, push changes:
105+
121106
```bash
122107
git push origin your-name/issue-identifier
123108
```
109+
124110
- A force push may be required:
111+
125112
```bash
126113
git push origin your-name/issue-identifier --force-with-lease
127114
```

macros.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,7 @@ def nav_to_dict(nav): # type: ignore
112112
def dict_to_md(nav_dict, depth=0) -> str:
113113
if isinstance(nav_dict, list):
114114
return "\n\n".join(dict_to_md(section, depth) for section in nav_dict)
115-
indented_prefix = f"{' ' * depth}- "
115+
indented_prefix = f"{' ' * depth}- "
116116
if isinstance(nav_dict, dict):
117117
if "title" in nav_dict:
118118
title = nav_dict["title"]

0 commit comments

Comments
 (0)