Skip to content

Nightly

Nightly #1887

Workflow file for this run

name: Nightly
on:
workflow_dispatch:
schedule:
- cron: '53 7 * * *'
permissions:
contents: read
jobs:
linux:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Install ghc
run: |
ghcup install ghc --set 9.4.4
- name: Install dependencies
run: |
ghc --version
cabal --version
cabal update
cabal build --dependencies-only -fembed_data_files -fnightly pandoc-cli
- name: Build and install artifact
run: |
export ARTIFACTS=nightly-linux/pandoc-nightly-linux-$(date +%Y-%m-%d)
mkdir -p ${ARTIFACTS}
cabal install --installdir="${ARTIFACTS}" --install-method=copy -fembed_data_files -fnightly pandoc-cli
strip "${ARTIFACTS}/pandoc"
cp COPYRIGHT ${ARTIFACTS}/
echo "Built from ${GITHUB_SHA}" > ${ARTIFACTS}/README.nightly.txt
- uses: actions/upload-artifact@v4
with:
name: nightly-linux
path: nightly-linux
windows:
runs-on: windows-2019
steps:
- uses: actions/checkout@v4
- name: Install ghc
run: |
ghcup install ghc --set 9.4.4
- name: Install dependencies
run: |
cabal update
cabal build --dependencies-only -fembed_data_files -fnightly pandoc-cli
- name: Build artifacts
shell: cmd
run: |
for /f %%a in ('powershell -Command "Get-Date -format yyyy-MM-dd"') do set THEDATE=%%a
set ARTIFACTS=%CD%\nightly-windows\pandoc-nightly-windows-%THEDATE%
mkdir %ARTIFACTS%
cabal install --install-method=copy --installdir=%ARTIFACTS% -fnightly -fembed_data_files pandoc-cli
strip %ARTIFACTS%/pandoc
copy COPYRIGHT %ARTIFACTS%
ren %ARTIFACTS%\COPYRIGHT COPYRIGHT.txt
echo Built from %GITHUB_SHA% > %ARTIFACTS%\README.nightly.txt
- uses: actions/upload-artifact@v4
with:
name: nightly-windows
path: nightly-windows
macos:
runs-on: macos-13
steps:
- uses: actions/checkout@v4
- name: Install ghcup
run: |
brew install ghcup
- name: Install ghc
run: |
ghcup install ghc --set 9.4
ghcup install cabal --set 3.10
echo "$HOME/.ghcup/bin" >> "${GITHUB_PATH}"
- name: Install dependencies
run: |
cabal update
cabal build --dependencies-only -fnightly -fembed_data_files pandoc-cli
- name: Build artifacts
run: |
export ARTIFACTS=nightly-macos/pandoc-nightly-macos-$(date +%Y-%m-%d)
mkdir -p ${ARTIFACTS}
cabal install --install-method=copy --installdir="${ARTIFACTS}" -fnightly -fembed_data_files pandoc-cli
strip "${ARTIFACTS}/pandoc"
cp COPYRIGHT ${ARTIFACTS}/
echo "Built from ${GITHUB_SHA}" > ${ARTIFACTS}/README.nightly.txt
- uses: actions/upload-artifact@v4
with:
name: nightly-macos
path: nightly-macos