|
| 1 | +[](https://twitter.com/vosough_k) |
| 2 | +[](https://www.linkedin.com/in/kiarashvosough/) |
| 3 | + |
| 4 | +DocC Github Pages Deploy: Deploy Generated DocC Static Site To Github-Pages. |
| 5 | + |
| 6 | +- [Requirements](#requirements) |
| 7 | +- [Usage](#usage) |
| 8 | +- [Integration](#integration-with-build-docC-static-site) |
| 9 | +- [Contributors](#contributors) |
| 10 | +- [License](#license) |
| 11 | + |
| 12 | +## Requirements |
| 13 | + |
| 14 | +| Platform | Status | |
| 15 | +| --- | --- | |
| 16 | +| ubuntu-latest | Tested | |
| 17 | + |
| 18 | +## Usage |
| 19 | + |
| 20 | +See [action.yml](https://github.com/kiarashvosough1999/docC-github-pages-deploy/blob/master/action.yml). |
| 21 | + |
| 22 | +As An Example: |
| 23 | + |
| 24 | +```yml |
| 25 | +name: worksapce |
| 26 | +on: |
| 27 | + push: |
| 28 | + branches: |
| 29 | + - '**' |
| 30 | +jobs: |
| 31 | + build_deploy_site: |
| 32 | + runs-on: ubuntu-latest |
| 33 | + environment: |
| 34 | + name: github-pages |
| 35 | + url: ${{ steps.deployment.outputs.page_url }} |
| 36 | + |
| 37 | + permissions: |
| 38 | + pages: write |
| 39 | + contents: read |
| 40 | + id-token: write |
| 41 | + |
| 42 | + steps: |
| 43 | + - name: deploy static site |
| 44 | + uses: kiarashvosough1999/docC-github-pages-deploy@added-action-steps |
| 45 | +``` |
| 46 | +
|
| 47 | +> Make Sure give access to `pages`, `contents` and `d-token`, or the action will fail to push the site into Github-Pages. |
| 48 | + |
| 49 | +> Make sure to specify the `name` and `url` on the environment like the example, or the job will fail. |
| 50 | + |
| 51 | + |
| 52 | +## Integration With Build DocC Static Site |
| 53 | + |
| 54 | +You can use [https://github.com/kiarashvosough1999/build-docC-static-site/tree/master) to generate static site from DocC Archive. |
| 55 | + |
| 56 | +> The default `docC-generated-static-site-uploaded-name` associated with [build-docC-static-site |
| 57 | +](https://github.com/kiarashvosough1999/build-docC-static-site/tree/master) and `docC-generated-static-site-zipped-upload-name` associated with this action, input must be the same. |
| 58 | + |
| 59 | +> This action will unzip the input static site with `gtar` and `tar` extension. So do not specify the zip extension on either `docC-generated-static-site-uploaded-name` or `docC-generated-static-site-zipped-upload-name`. |
| 60 | + |
| 61 | +## Contributors |
| 62 | + |
| 63 | +Feel free to share your ideas or any other problems. Pull requests are welcomed. |
| 64 | + |
| 65 | +## License |
| 66 | + |
| 67 | +CocoAttributedStringBuilder is released under an MIT license. See [LICENSE](https://github.com/kiarashvosough1999/build-docC-static-site/blob/master/LICENSE) for more information. |
0 commit comments