Skip to content

Commit 4053bb6

Browse files
committed
Start a doc site
1 parent 31af29c commit 4053bb6

File tree

7 files changed

+92
-29
lines changed

7 files changed

+92
-29
lines changed

.eslintrc.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
"es6": true,
55
"node": true
66
},
7+
"ignorePatterns": ["site/"],
78
"extends": "eslint:recommended",
89
"globals": {
910
"Atomics": "readonly",

.github/workflows/deploy-docs.yml

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
name: Deploy docs
2+
on:
3+
push:
4+
pull_request:
5+
schedule:
6+
- cron: '0 6 * * 6'
7+
jobs:
8+
build:
9+
name: Deploy docs
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Download source
13+
uses: actions/checkout@v2
14+
- name: Install Python
15+
uses: actions/setup-python@v2
16+
- name: Install dependencies
17+
run: pip install -r docs/requirements.txt
18+
- name: Build site
19+
run: mkdocs build
20+
working-directory: docs
21+
- name: Deploy to gh-pages
22+
if: github.event_name == 'push' && github.ref == 'refs/heads/master'
23+
uses: oprypin/push-to-gh-pages@v3
24+
with:
25+
publish_dir: site
26+
commit_message: 'Generate docs: '

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,3 @@
11
node_modules/
22
.vscode/
3+
site/

README.md

Lines changed: 29 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -52,64 +52,64 @@ Alternatively, you can use the container-based approach [as in the starter workf
5252
5353
### Inputs
5454
55-
* * **`crystal: 0.35.1`** (not supported on Windows)
55+
* * **`crystal: 0.35.1`** (not supported on Windows)
5656

57-
Install a particular release of Crystal.
57+
Install a particular release of Crystal.
5858

59-
* **`crystal: latest`** (default; not supported on Windows)
59+
* **`crystal: latest`** (default; not supported on Windows)
6060

61-
Install the latest released version of Crystal.
61+
Install the latest released version of Crystal.
6262

63-
* **`crystal: nightly`** (default on Windows)
63+
* **`crystal: nightly`** (default on Windows)
6464

65-
Install Crystal from the latest continuous build on [crystal.git][] master.
65+
Install Crystal from the latest continuous build on [crystal.git][] master.
6666

67-
* * **`shards: true`** (default)
67+
* * **`shards: true`** (default)
6868

69-
Ensure that *some* released version of [Shards][] is available.
70-
This uses the build that's bundled with Crystal's releases. Other options are slower, as building Shards is a necessary step then.
69+
Ensure that *some* released version of [Shards][] is available.
70+
This uses the build that's bundled with Crystal's releases. Other options are slower, as building Shards is a necessary step then.
7171

72-
* **`shards: false`**
72+
* **`shards: false`**
7373

74-
Ensure that `shards` executable is *not* available.
74+
Ensure that `shards` executable is *not* available.
7575

76-
* **`shards: latest`**
76+
* **`shards: latest`**
7777

78-
Build and install the latest released version of Shards.
78+
Build and install the latest released version of Shards.
7979

80-
* **`shards: 0.13.0`**
80+
* **`shards: 0.13.0`**
8181

82-
Build and install a particular release of Shards.
82+
Build and install a particular release of Shards.
8383

84-
* **`shards: nightly`**
84+
* **`shards: nightly`**
8585

86-
Build and install the latest commit of [shards.git][] master.
86+
Build and install the latest commit of [shards.git][] master.
8787

88-
* **`arch: x86_64`**, **`arch: x86`** (defaults to current OS arch)
88+
* **`arch: x86_64`**, **`arch: x86`** (defaults to current OS arch)
8989

90-
The architecture of the build of Crystal to download.
90+
The architecture of the build of Crystal to download.
9191

92-
* **`destination: some/path`**
92+
* **`destination: some/path`**
9393

94-
The directory to store Crystal in, after extracting. Will directly affect `outputs.path` (the default is in a temporary location).
94+
The directory to store Crystal in, after extracting. Will directly affect `outputs.path` (the default is in a temporary location).
9595

96-
* **`token: ${{ github.token }}`**
96+
* **`token: ${{ github.token }}`**
9797

98-
Personal access token (auto-populated).
98+
Personal access token (auto-populated).
9999

100100
### Outputs
101101

102-
* **`crystal`** (`${{ steps.some_step_id.outputs.crystal }}`)
102+
* **`crystal`** (`${{ steps.some_step_id.outputs.crystal }}`)
103103

104-
The actual version of Crystal (as a ref in crystal-lang/[crystal.git][]) that was installed.
104+
The actual version of Crystal (as a ref in crystal-lang/[crystal.git][]) that was installed.
105105

106-
* **`shards`** (`${{ steps.some_step_id.outputs.shards }}`)
106+
* **`shards`** (`${{ steps.some_step_id.outputs.shards }}`)
107107

108-
The actual version of Shards (as a ref in crystal-lang/[shards.git][]) that was installed.
108+
The actual version of Shards (as a ref in crystal-lang/[shards.git][]) that was installed.
109109

110-
* **`path`** (`${{ steps.some_step_id.outputs.path }}`)
110+
* **`path`** (`${{ steps.some_step_id.outputs.path }}`)
111111

112-
The path where Crystal was extracted to, so you can use '[path]/bin/crystal', '[path]/src' etc.
112+
The path where Crystal was extracted to, so you can use '[path]/bin/crystal', '[path]/src' etc.
113113

114114
[github action]: https://github.com/features/actions
115115
[crystal]: https://crystal-lang.org/

docs/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
--8<-- "../README.md"

docs/mkdocs.yml

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
site_name: install-crystal action
2+
site_url: "https://oprypin.github.io/install-crystal"
3+
repo_url: "https://github.com/oprypin/install-crystal"
4+
edit_uri: blob/master/docs/
5+
use_directory_urls: false
6+
docs_dir: .
7+
site_dir: ../site
8+
9+
theme:
10+
name: material
11+
icon:
12+
repo: fontawesome/brands/github
13+
palette:
14+
primary: teal
15+
accent: purple
16+
17+
plugins:
18+
- search
19+
- same-dir
20+
21+
markdown_extensions:
22+
- pymdownx.highlight
23+
- pymdownx.magiclink
24+
- pymdownx.superfences
25+
- pymdownx.details
26+
- pymdownx.snippets:
27+
check_paths: true
28+
- admonition
29+
- def_list
30+
- toc:
31+
permalink: "#"

docs/requirements.txt

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
mkdocs
2+
mkdocs-material
3+
mkdocs-same-dir

0 commit comments

Comments
 (0)