File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ name : Deploy site to GitHub Pages
2+
3+ on :
4+ workflow_dispatch :
5+ push :
6+ branches : [main]
7+ paths :
8+ - ' index.html'
9+ - ' assets/**'
10+ - ' data/**'
11+ - ' .github/workflows/deploy-pages.yml'
12+
13+ permissions :
14+ contents : read
15+ pages : write
16+ id-token : write
17+
18+ concurrency :
19+ group : github-pages
20+ cancel-in-progress : false
21+
22+ jobs :
23+ build :
24+ name : Package static site
25+ runs-on : ubuntu-latest
26+
27+ steps :
28+ - name : Check out the site
29+ uses : actions/checkout@v6
30+
31+ - name : Configure GitHub Pages
32+ uses : actions/configure-pages@v5
33+
34+ - name : Collect published files
35+ run : |
36+ mkdir _site
37+ cp index.html _site/
38+ cp -R assets data _site/
39+
40+ - name : Upload Pages artifact
41+ uses : actions/upload-pages-artifact@v3
42+ with :
43+ path : _site
44+
45+ deploy :
46+ name : Publish GitHub Pages site
47+ needs : build
48+ runs-on : ubuntu-latest
49+ environment :
50+ name : github-pages
51+ url : ${{ steps.deployment.outputs.page_url }}
52+
53+ steps :
54+ - name : Deploy artifact
55+ id : deployment
56+ uses : actions/deploy-pages@v4
Original file line number Diff line number Diff line change @@ -103,3 +103,16 @@ atualiza — o PR `automation/meetup-events` somente quando houver diferença.
103103Antes do primeiro uso, habilite em ** Settings → Actions → General → Workflow
104104permissions** a opção de leitura e escrita e permita que o GitHub Actions crie
105105pull requests. Não há segredo ou credencial do Meetup no workflow.
106+
107+ ## Publicação no GitHub Pages
108+
109+ O workflow ` .github/workflows/deploy-pages.yml ` publica ` index.html ` , ` assets/ `
110+ e ` data/ ` quando mudanças desses arquivos chegam à ` main ` ; ele também pode ser
111+ executado manualmente. O JSON aprovado no PR de eventos, portanto, é publicado
112+ no próximo merge sem exigir uma cópia local do repositório.
113+
114+ Antes da primeira publicação, configure em ** Settings → Pages → Build and
115+ deployment** a origem como ** GitHub Actions** . Para este repositório, a URL
116+ padrão será ` https://pythonmg.github.io/site-pythonmg/ ` . O domínio
117+ ` pythonmg.github.io ` exige uma configuração de domínio personalizado ou um
118+ repositório de usuário/organização com esse nome.
You can’t perform that action at this time.
0 commit comments