Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
37 commits
Select commit Hold shift + click to select a range
a891f21
List tags
nhuet Nov 30, 2021
ddc0551
List remote
nhuet Nov 30, 2021
db1d68f
Fetch toto
nhuet Nov 30, 2021
8f1ede4
Add --all
nhuet Nov 30, 2021
7f820e0
Tag binder env on releases
nhuet Nov 30, 2021
85ea8ab
Add identity
nhuet Nov 30, 2021
0b44627
Add identity again
nhuet Nov 30, 2021
30a6502
Create binder env in a separate job
nhuet Nov 30, 2021
a208112
Fix yaml
nhuet Nov 30, 2021
e5dd06b
Use new binder env in doc
nhuet Nov 30, 2021
8b13114
Cache binder build on mybinder.org
nhuet Nov 30, 2021
9cb6e58
Change the way the env var BINDER_TAG is passed
nhuet Nov 30, 2021
e9b7bb3
Test env variable context
nhuet Nov 30, 2021
bbf13b3
Use env.BINDER_TAG to reference binder env branch
nhuet Nov 30, 2021
8cbe913
Build binder docker image
nhuet Dec 2, 2021
e4cedb1
Test variables
nhuet Dec 3, 2021
be72a6b
Add test
nhuet Dec 3, 2021
1020f4e
external pr
nhuet Oct 26, 2021
beeb323
advance pr
nhuet Oct 26, 2021
e361cb6
ok
nhuet Oct 26, 2021
45a844b
external pr 2
nhuet Oct 26, 2021
e80fdb0
Yo
nhuet Dec 3, 2021
02e9fea
Yo
nhuet Dec 3, 2021
4e8ccce
Git chckout other branch
nhuet Dec 3, 2021
a6a094d
Add depth option
nhuet Dec 3, 2021
ed2b6a6
Less log
nhuet Dec 3, 2021
b4a83f6
Start at binder and go back to merge commitwq
nhuet Dec 3, 2021
9420002
Another context varwq
nhuet Dec 3, 2021
a28b173
Switch checkout order
nhuet Dec 3, 2021
44d30ed
Do not checkout binder in the checkout action
nhuet Dec 3, 2021
9f90100
Testwq
nhuet Dec 3, 2021
698f553
Testwq
nhuet Dec 3, 2021
359f398
TePO
nhuet Dec 3, 2021
fee73fa
ok
nhuet Dec 3, 2021
f8b2b6b
Checkout binder in action
nhuet Dec 3, 2021
fe05d8f
OK
nhuet Dec 3, 2021
62a48bf
Test commit during CI
nhuet Dec 3, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 30 additions & 1 deletion .github/workflows/blank.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,34 @@ jobs:
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Tests
run: |
echo $GITHUB_REF
echo ${{ github.ref }}
echo ${{ github.ref_name }}
echo ${{ github.head_ref }}
echo ${{ github.base_ref }}
echo ${{ github.repository }}
echo $GITHUB_REPOSITORY

echo "******** BINDER *********"
git checkout binder
ls
echo ${{ github.sha }} > sha1.txt
git add sha1.txt
git config user.name "Binder Bot"
git commit -m "edit sha1"
git push origin binder


echo "******** CURRENT REF *********"
LOCAL_REF=${GITHUB_REF/refs\//}
echo LOCAL_REF=$LOCAL_REF
git checkout ${LOCAL_REF}
ls

- name: Set env variables for github+binder links in doc
run: |
Expand Down Expand Up @@ -53,6 +81,8 @@ jobs:
echo ${AUTODOC_NOTEBOOKS_REPO_URL}
echo ${AUTODOC_NOTEBOOKS_BRANCH}

echo nb_branch: ${{ env.AUTODOC_NOTEBOOKS_BRANCH }}

# Runs a single command using the runners shell
- name: Run a one-line script
run: echo ${{ github.ref }}
Expand All @@ -65,4 +95,3 @@ jobs:
- name: deploy
if: ${{ github.ref == 'refs/heads/main' }}
run: echo deploy

81 changes: 40 additions & 41 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,57 +10,56 @@ on:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
create-binder-env:
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- name: Get scikit-decide release version and define new binder env tag
run: |
TAG_NAME=${GITHUB_REF/refs\/tags\//} # stripping "refs/tags/"
SKDECIDE_VERSION=${TAG_NAME/v/} # stripping "v"
BINDER_TAG=binder_${TAG_NAME}
echo "BINDER_TAG=${BINDER_TAG}" >> $GITHUB_ENV
echo "SKDECIDE_VERSION=${SKDECIDE_VERSION}" >> $GITHUB_ENV

# Checks-out binder branch
- uses: actions/checkout@v2
with:
ref: binder

- name: Update scikit-decide dependency and tag the environement
run: |
sed -e "s/scikit-decide\[all\]==.*/scikit-decide\[all\]==${SKDECIDE_VERSION}/" environment.yml > environment.yml.new
mv environment.yml.new environment.yml
git config user.name "Binder Bot"
git config user.email "binder@bot.com"
git commit environment.yml -m "Update scikit-decide dependency"
git tag -a ${BINDER_TAG} -m "Release binder environment for scikit-decide ${SKDECIDE_VERSION}"
git push origin ${BINDER_TAG}

- name: cache binder build on mybinder.org
uses: jupyterhub/repo2docker-action@master
with:
NO_PUSH: true
MYBINDERORG_TAG: ${{ env.BINDER_TAG }}

build-docs:
runs-on: ubuntu-latest
env:
DOCS_VERSION_PATH: /

steps:
- name: Set env variables for github+binder links in doc
run: |
# binder environment repo and branch
AUTODOC_BINDER_ENV_GH_REPO_NAME="airbus/scikit-decide"
AUTODOC_BINDER_ENV_GH_BRANCH="binder"
# notebooks source repo and branch depending if it is a commit push or a PR
if [[ $GITHUB_REF == refs/pull* ]];
then
AUTODOC_NOTEBOOKS_REPO_URL="${GITHUB_SERVER_URL}/${{ github.event.pull_request.head.repo.full_name }}"
AUTODOC_NOTEBOOKS_BRANCH=${GITHUB_HEAD_REF}
elif [[ $GITHUB_REF == refs/heads* ]];
then
AUTODOC_NOTEBOOKS_REPO_URL=${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}
AUTODOC_NOTEBOOKS_BRANCH=${GITHUB_REF/refs\/heads\//}
fi
# export in GITHUB_ENV for next steps
echo "AUTODOC_BINDER_ENV_GH_REPO_NAME=${AUTODOC_BINDER_ENV_GH_REPO_NAME}" >> $GITHUB_ENV
echo "AUTODOC_BINDER_ENV_GH_BRANCH=${AUTODOC_BINDER_ENV_GH_BRANCH}" >> $GITHUB_ENV
echo "AUTODOC_NOTEBOOKS_REPO_URL=${AUTODOC_NOTEBOOKS_REPO_URL}" >> $GITHUB_ENV
echo "AUTODOC_NOTEBOOKS_BRANCH=${AUTODOC_NOTEBOOKS_BRANCH}" >> $GITHUB_ENV
# check computed variables
echo "Binder env: ${AUTODOC_BINDER_ENV_GH_REPO_NAME}/${AUTODOC_BINDER_ENV_GH_BRANCH}"
echo "Notebooks source: ${AUTODOC_NOTEBOOKS_REPO_URL}/tree/${AUTODOC_NOTEBOOKS_BRANCH}"
TAG_NAME=${GITHUB_REF/refs\/tags\//} # stripping "refs/tags/"
BINDER_TAG=binder_${TAG_NAME}
echo "AUTODOC_BINDER_ENV_GH_REPO_NAME=airbus/scikit-decide" >> $GITHUB_ENV
echo "AUTODOC_BINDER_ENV_GH_BRANCH=${BINDER_TAG}" >> $GITHUB_ENV
echo "AUTODOC_NOTEBOOKS_REPO_URL=${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}" >> $GITHUB_ENV
echo "AUTODOC_NOTEBOOKS_BRANCH=${TAG_NAME}" >> $GITHUB_ENV

- name: read binder env
run: |
echo ${AUTODOC_BINDER_ENV_GH_REPO_NAME}
echo ${AUTODOC_BINDER_ENV_GH_BRANCH}
echo ${AUTODOC_NOTEBOOKS_REPO_URL}
echo ${AUTODOC_NOTEBOOKS_BRANCH}

# Runs a single command using the runners shell
- name: Run a one-line script
run: echo ${{ github.ref }}

# Runs a set of commands using the runners shell
- name: Run a multi-line script
run: |
echo Add other actions to build,
echo test, and deploy your project.
- name: deploy
if: ${{ github.ref == 'refs/heads/main' }}
run: echo deploy

Empty file added another
Empty file.
Empty file added anotherone
Empty file.
Empty file added ko
Empty file.
Empty file added newfile
Empty file.
Empty file added yo
Empty file.
Empty file added yoyo
Empty file.