Skip to content

Commit

Permalink
update to latest Generated `/home/runner/work/pretext-cli/pretext-cli…
Browse files Browse the repository at this point in the history
…/codechat_config.yaml`

Generated `/home/runner/work/pretext-cli/pretext-cli/.gitignore`

Generated `/home/runner/work/pretext-cli/pretext-cli/.devcontainer.json`

Generated `/home/runner/work/pretext-cli/pretext-cli/requirements.txt`

Generated `/home/runner/work/pretext-cli/pretext-cli/.github/workflows/pretext-cli.yml`

PreTeXt-CLI version: 2.5.0

PreTeXt project found in `/home/runner/work/pretext-cli/pretext-cli`.
�[31merror: �[0mA project already exists in `/home/runner/work/pretext-cli/pretext-cli`.
�[31merror: �[0mNo new project will be generated.

----------------------------------------------------
While running pretext, the following errors occurred:

(see log messages above or in the 'logs' folder for more information)
----------------------------------------------------
  • Loading branch information
oscarlevin committed Jul 16, 2024
1 parent d7d0234 commit 5af3747
Show file tree
Hide file tree
Showing 5 changed files with 100 additions and 111 deletions.
74 changes: 0 additions & 74 deletions .github/workflows/deploy.yml

This file was deleted.

93 changes: 93 additions & 0 deletions .github/workflows/pretext-cli.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
# <!-- Managed automatically by PreTeXt authoring tools -->
# (delete the above line to manage this file manually)

name: PreTeXt-CLI Actions
on:
# Runs on pull requests
pull_request:
branches: ["*"]
# Runs on pushes to main
push:
branches: ["main"]
# Runs on demand
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
container: oscarlevin/pretext:full

steps:
- name: Checkout source
uses: actions/checkout@v4

- name: install deps
run: pip install -r requirements.txt

- name: build deploy targets
run: pretext build --deploys
- name: stage deployment
run: pretext deploy --stage-only

- name: Bundle output/stage as artifact
uses: actions/upload-artifact@v4
with:
name: deploy
path: output/stage

deploy-cloudflare:
runs-on: ubuntu-latest
needs: build
if: vars.CLOUDFLARE_PROJECT_NAME != ''
permissions:
contents: read
deployments: write

steps:
- name: Download artifact
uses: actions/download-artifact@v4
with:
name: deploy
path: deploy
- name: Create 404.html
run: echo "404 page not found" >> deploy/404.html
- name: Publish to Cloudflare
uses: cloudflare/pages-action@v1
with:
apiToken: ${{ secrets.CLOUDFLARE_API_TOKEN }}
accountId: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
projectName: ${{ vars.CLOUDFLARE_PROJECT_NAME }}
gitHubToken: ${{ secrets.GITHUB_TOKEN }}
branch: ${{ github.head_ref || github.ref_name }}
directory: deploy

deploy-ghpages:
runs-on: ubuntu-latest
needs: build
if: vars.PTX_ENABLE_DEPLOY_GHPAGES == 'yes' && github.ref == format('refs/heads/{0}', github.event.repository.default_branch)
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: "page"
cancel-in-progress: false
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- name: Download website artifact
uses: actions/download-artifact@v4
with:
name: deploy
path: deploy
- name: Setup GitHub Pages
id: check
uses: actions/configure-pages@v4
- name: Upload artifact
uses: actions/upload-pages-artifact@v3
with:
path: deploy
- name: Deploy to Github Pages
id: deployment
uses: actions/deploy-pages@v4
35 changes: 0 additions & 35 deletions .github/workflows/test-build.yml

This file was deleted.

7 changes: 6 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
# ensure this file is tracked
!.gitignore

# don't track unpublished builds or stage
# don't track unpublished builds or stage (note: Runestone uses `published`)
output
published

# don't track assets generated from source
generated-assets
Expand Down Expand Up @@ -97,3 +98,7 @@ GitHub.sublime-settings

# Don't track codechat config (will be generated automatically)
codechat_config.yaml

# Don't track deprecated workflows
.github/workflows/deploy.yml
.github/workflows/test-build.yml
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
# <!-- Managed automatically by PreTeXt authoring tools -->
pretext == 2.4.1
pretext == 2.5.0

0 comments on commit 5af3747

Please sign in to comment.