mirror of
https://github.com/vale981/emacs-jupyter
synced 2025-03-06 16:01:37 -05:00
Add a GitHub test workflow
This commit is contained in:
parent
dabcf2a5b8
commit
79cc6daa09
1 changed files with 48 additions and 0 deletions
48
.github/workflows/test.yml
vendored
Normal file
48
.github/workflows/test.yml
vendored
Normal file
|
@ -0,0 +1,48 @@
|
|||
on: push
|
||||
jobs:
|
||||
test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- uses: cachix/install-nix-action@v18
|
||||
with:
|
||||
nix_path: nixpkgs=channel:nixos-unstable
|
||||
extra_nix_config: |
|
||||
access-tokens = github.com=${{ secrets.GITHUB_TOKEN }}
|
||||
- uses: purcell/setup-emacs@master
|
||||
with:
|
||||
version: 27.2
|
||||
- run: |
|
||||
cat << 'EOF' > script.sh
|
||||
#!/usr/bin/env bash
|
||||
mkdir -p $(jupyter --runtime-dir)
|
||||
jupyter --paths
|
||||
jupyter --version
|
||||
jupyter kernelspec list
|
||||
|
||||
make dev
|
||||
make compile
|
||||
make test
|
||||
EOF
|
||||
|
||||
cat << EOF > shell.nix
|
||||
{ pkgs ? import <nixpkgs> {} }:
|
||||
let
|
||||
pypkgs = p: with p; [
|
||||
jupyter-core
|
||||
jupyter-client
|
||||
ipykernel
|
||||
notebook
|
||||
];
|
||||
in pkgs.mkShell {
|
||||
packages = [
|
||||
pkgs.pandoc
|
||||
(pkgs.python3.withPackages pypkgs)
|
||||
];
|
||||
}
|
||||
EOF
|
||||
|
||||
git clone https://github.com/cask/cask ~/.cask
|
||||
export PATH=$HOME/.cask/bin:$PATH
|
||||
chmod +x script.sh
|
||||
nix-shell --run ./script.sh
|
Loading…
Add table
Reference in a new issue