Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pin dependencies using single configuration file #88

Merged
merged 1 commit into from
Jun 19, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
9 changes: 8 additions & 1 deletion .github/workflows/cpp-prep-dep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ directory=$1
repository=$2
version=$3

if [[ -z $version && $version != "latest" ]];
then
# use the dependencies
source dependencies.cfg
version="${!directory}"
fi

cd ~/.tscan-deps
if [ ! -d $directory ];
then
Expand All @@ -15,7 +22,7 @@ fi
cd $directory
old_commit_hash=$(git rev-parse HEAD)

if [[ -z $version ]];
if [[ -z $version || $version == "latest" ]];
then
echo "Get latest version"
git pull
Expand Down
34 changes: 9 additions & 25 deletions .github/workflows/cpp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,22 +32,6 @@ jobs:
OPENMPFLAG: --disable-openmp
}
dependencies: [ pinned ] # TODO: latest is known to fail //, latest ]
include:
# - dependencies: latest
# alpino: Alpino-x86_64-Linux-glibc-2.17-git819-sicstus
# versions known to works
- dependencies: pinned
# removed for speed, using pre-parsed trees only
# alpino: Alpino-x86_64-Linux-glibc-2.17-git819-sicstus
ticcutils: ecb62eb116ffc3677626c53f012f34e00854e4c4 # 0.33 2023-04-29
libfolia: 1a3f462f8f048df60889817325701130b6271e8a # 2.15 2023-05-01
uctodata: a8be6cf7512998f4c8963d1021f402b8b1290085 # 0.9.1 2022-10-04
ucto: d22029833b264a969351ead0ee3ab9b3f97db97d # 0.30 2023-04-29
timbl: 61929ce6dc7d7077cb5eeceafef86de38eb40daa # 6.9 2023-04-29
mbt: fd7cb7ebdd52bef2794f16f329569bedad3143e9 # 3.10 2023-04-29
mbtserver: a6f04f30f62965c8660ee92be99d4eb86fc4bf65 # 0.17 2023-04-30
frogdata: 99de9597105c2304faeb797264231ba180fcdb20 # 0.22 2023-03-07
frog: 991f6977cfd81b9a6538db0c6de3d26908ec16b7 # 0.29 2023-05-03
env:
CC: ${{ matrix.compiler.CC }}
CXX: ${{ matrix.compiler.CXX }}
Expand Down Expand Up @@ -98,31 +82,31 @@ jobs:

- name: Install ticcutils
run: |
.github/workflows/cpp-prep-dep.sh ticcutils https://github.com/LanguageMachines/ticcutils "${{ matrix.ticcutils }}"
.github/workflows/cpp-prep-dep.sh ticcutils https://github.com/LanguageMachines/ticcutils
- name: Install libfolia
run: |
.github/workflows/cpp-prep-dep.sh libfolia https://github.com/LanguageMachines/libfolia "${{ matrix.libfolia }}"
.github/workflows/cpp-prep-dep.sh libfolia https://github.com/LanguageMachines/libfolia
- name: Install uctodata
run: |
.github/workflows/cpp-prep-dep.sh uctodata https://github.com/LanguageMachines/uctodata "${{ matrix.uctodata }}"
.github/workflows/cpp-prep-dep.sh uctodata https://github.com/LanguageMachines/uctodata
- name: Install ucto
run: |
.github/workflows/cpp-prep-dep.sh ucto https://github.com/LanguageMachines/ucto "${{ matrix.ucto }}"
.github/workflows/cpp-prep-dep.sh ucto https://github.com/LanguageMachines/ucto
- name: Install timbl
run: |
.github/workflows/cpp-prep-dep.sh timbl https://github.com/LanguageMachines/timbl "${{ matrix.timbl }}"
.github/workflows/cpp-prep-dep.sh timbl https://github.com/LanguageMachines/timbl
- name: Install mbt
run: |
.github/workflows/cpp-prep-dep.sh mbt https://github.com/LanguageMachines/mbt "${{ matrix.mbt }}"
.github/workflows/cpp-prep-dep.sh mbt https://github.com/LanguageMachines/mbt
- name: Install mbtserver
run: |
.github/workflows/cpp-prep-dep.sh mbtserver https://github.com/LanguageMachines/mbtserver "${{ matrix.mbtserver }}"
.github/workflows/cpp-prep-dep.sh mbtserver https://github.com/LanguageMachines/mbtserver
- name: Install frogdata
run: |
.github/workflows/cpp-prep-dep.sh frogdata https://github.com/LanguageMachines/frogdata "${{ matrix.frogdata }}"
.github/workflows/cpp-prep-dep.sh frogdata https://github.com/LanguageMachines/frogdata
- name: Install frog
run: |
.github/workflows/cpp-prep-dep.sh frog https://github.com/LanguageMachines/frog "${{ matrix.frog }}"
.github/workflows/cpp-prep-dep.sh frog https://github.com/LanguageMachines/frog
- name: Install
run: |
bash bootstrap.sh
Expand Down
21 changes: 11 additions & 10 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -120,16 +120,17 @@ WORKDIR /deployment
RUN ./add-alpino.sh
# These will create .deb packages which can be re-used by the final container
# or during a rebuild
RUN ./prep-dep.sh ticcutils https://github.com/LanguageMachines/ticcutils ecb62eb116ffc3677626c53f012f34e00854e4c4
RUN ./prep-dep.sh libfolia https://github.com/LanguageMachines/libfolia 1a3f462f8f048df60889817325701130b6271e8a
RUN ./prep-dep.sh uctodata https://github.com/LanguageMachines/uctodata a8be6cf7512998f4c8963d1021f402b8b1290085
RUN ./prep-dep.sh ucto https://github.com/LanguageMachines/ucto d22029833b264a969351ead0ee3ab9b3f97db97d
RUN ./prep-dep.sh timbl https://github.com/LanguageMachines/timbl 61929ce6dc7d7077cb5eeceafef86de38eb40daa
RUN ./prep-dep.sh mbt https://github.com/LanguageMachines/mbt fd7cb7ebdd52bef2794f16f329569bedad3143e9
RUN ./prep-dep.sh mbtserver https://github.com/LanguageMachines/mbtserver a6f04f30f62965c8660ee92be99d4eb86fc4bf65
RUN ./prep-dep.sh frogdata https://github.com/LanguageMachines/frogdata 99de9597105c2304faeb797264231ba180fcdb20
RUN ./prep-dep.sh frog https://github.com/LanguageMachines/frog 991f6977cfd81b9a6538db0c6de3d26908ec16b7
RUN ./prep-dep.sh wopr https://github.com/LanguageMachines/wopr 6e3068047c0f9d3c66fcedb9c25e68907770ac9d
COPY dependencies.cfg /src/tscan/
RUN ./prep-dep.sh ticcutils https://github.com/LanguageMachines/ticcutils
RUN ./prep-dep.sh libfolia https://github.com/LanguageMachines/libfolia
RUN ./prep-dep.sh uctodata https://github.com/LanguageMachines/uctodata
RUN ./prep-dep.sh ucto https://github.com/LanguageMachines/ucto
RUN ./prep-dep.sh timbl https://github.com/LanguageMachines/timbl
RUN ./prep-dep.sh mbt https://github.com/LanguageMachines/mbt
RUN ./prep-dep.sh mbtserver https://github.com/LanguageMachines/mbtserver
RUN ./prep-dep.sh frogdata https://github.com/LanguageMachines/frogdata
RUN ./prep-dep.sh frog https://github.com/LanguageMachines/frog
RUN ./prep-dep.sh wopr https://github.com/LanguageMachines/wopr

RUN ./build-compound-splitter.sh

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ We strongly recommend to use Docker to install T-scan. Be aware that T-scan and

This version of T-Scan can run directly from Docker:

$ docker-compose up
$ docker compose up

Default address: http://localhost:8830

Expand Down
11 changes: 11 additions & 0 deletions dependencies.cfg
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# List of the commit hashes to retrieve for the dependencies
ticcutils=ecb62eb116ffc3677626c53f012f34e00854e4c4 # 0.33 2023-04-29
libfolia=1a3f462f8f048df60889817325701130b6271e8a # 2.15 2023-05-01
uctodata=a8be6cf7512998f4c8963d1021f402b8b1290085 # 0.9.1 2022-10-04
ucto=d22029833b264a969351ead0ee3ab9b3f97db97d # 0.30 2023-04-29
timbl=61929ce6dc7d7077cb5eeceafef86de38eb40daa # 6.9 2023-04-29
mbt=fd7cb7ebdd52bef2794f16f329569bedad3143e9 # 3.10 2023-04-29
mbtserver=a6f04f30f62965c8660ee92be99d4eb86fc4bf65 # 0.17 2023-04-30
frogdata=99de9597105c2304faeb797264231ba180fcdb20 # 0.22 2023-03-07
frog=991f6977cfd81b9a6538db0c6de3d26908ec16b7 # 0.29 2023-05-03
wopr=6e3068047c0f9d3c66fcedb9c25e68907770ac9d
9 changes: 8 additions & 1 deletion docker/deployment/prep-dep.sh
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,14 @@ else
cd $directory
old_commit_hash=$(git rev-parse HEAD)

if [[ -z $version ]];
if [[ -z $version && $version != "latest" ]];
then
# use the dependencies
source /src/tscan/dependencies.cfg
version="${!directory}"
fi

if [[ -z $version || $version == "latest" ]];
then
echo "Using latest version"
elif [[ $version != $old_commit_hash ]];
Expand Down
Loading