Skip to content

Commit 3cd417e

Browse files
committed
Get rid of esy and rely
1 parent c4e6728 commit 3cd417e

File tree

88 files changed

+318
-4576
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

88 files changed

+318
-4576
lines changed

.github/workflows/ci.yml

Lines changed: 33 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -11,75 +11,55 @@ on:
1111
jobs:
1212
build:
1313
name: Build and test on ${{ matrix.os }}
14-
runs-on: ${{ matrix.os }}
1514
strategy:
1615
matrix:
17-
node-version: [14.x]
18-
os: [ubuntu-latest, macOS-latest, windows-2016]
16+
os:
17+
- macos-latest
18+
- ubuntu-latest
19+
- windows-latest
1920

20-
steps:
21-
- name: Use Node.js ${{ matrix.node-version }}
22-
uses: actions/setup-node@v1
23-
with:
24-
node-version: ${{ matrix.node-version }}
21+
runs-on: ${{ matrix.os }}
2522

23+
steps:
2624
- name: Checkout repository
2725
uses: actions/checkout@v2
2826

2927
- name: Checkout submodules
3028
run: git submodule update --init --recursive
3129

32-
- name: Install esy
33-
run: npm i -g [email protected]
34-
35-
- name: Restore esy install cache
36-
uses: actions/cache@v1
30+
- name: Use OCaml 4.06.1
31+
uses: ocaml/setup-ocaml@v2
3732
with:
38-
path: ~/.esy/source
39-
key: source-${{ hashFiles('**/index.json') }}
40-
41-
- name: esy install
42-
run: esy install
33+
ocaml-compiler: 4.06.1
4334

44-
- name: Get esy cache folder
45-
id: print_esy_cache
46-
run: node .github/workflows/print_esy_cache.js
47-
48-
- name: Restore esy build cache
49-
uses: actions/cache@v1
50-
with:
51-
path: ${{ steps.print_esy_cache.outputs.esy_cache }}
52-
key: build-${{ matrix.os }}-${{ hashFiles('**/index.json') }}
53-
restore-keys: build-${{ matrix.os }}-
35+
- name: OPAM install
36+
run: opam install . --deps-only --with-test
5437

5538
- name: Build
56-
run: |
57-
esy build
58-
# Cleanup build cache in case dependencies have changed
59-
esy cleanup .
39+
run: opam exec -- dune build
6040

6141
- name: Test
62-
run: esy test
42+
run: opam exec -- dune runtest
6343

64-
- name: (release only) Get artifact filenames
65-
id: get_filenames
66-
if: github.event_name != 'pull_request'
67-
run: node .github/workflows/get_filenames.js
44+
# - name: (release only) Get artifact filenames
45+
# id: get_filenames
46+
# if: github.event_name != 'pull_request'
47+
# run: node .github/workflows/get_filenames.js
6848

69-
- name: (release only) Get exe
70-
if: github.event_name != 'pull_request'
71-
shell: bash
72-
run: |
73-
# from https://stackoverflow.com/a/24848739/617787
74-
s=$(pwd); d=$(dirname $(esy x which Extract.exe));
75-
while [ "${d#$s/}" == "${d}" ]
76-
do s=$(dirname $s);b="../${b}"; done;
77-
ESY__BINARY_PATH=${b}${d#$s/}/Extract.exe
78-
mv "$ESY__BINARY_PATH" ${{ steps.get_filenames.outputs.exe_name }}
49+
# - name: (release only) Get exe
50+
# if: github.event_name != 'pull_request'
51+
# shell: bash
52+
# run: |
53+
# # from https://stackoverflow.com/a/24848739/617787
54+
# s=$(pwd); d=$(dirname $(esy x which Extract.exe));
55+
# while [ "${d#$s/}" == "${d}" ]
56+
# do s=$(dirname $s);b="../${b}"; done;
57+
# ESY__BINARY_PATH=${b}${d#$s/}/Extract.exe
58+
# mv "$ESY__BINARY_PATH" ${{ steps.get_filenames.outputs.exe_name }}
7959

80-
- name: (release only) Upload artifact ${{ matrix.os }}
81-
if: github.event_name != 'pull_request'
82-
uses: actions/upload-artifact@v2
83-
with:
84-
name: ${{ steps.get_filenames.outputs.artifact_name }}
85-
path: ${{ steps.get_filenames.outputs.exe_name }}
60+
# - name: (release only) Upload artifact ${{ matrix.os }}
61+
# if: github.event_name != 'pull_request'
62+
# uses: actions/upload-artifact@v2
63+
# with:
64+
# name: ${{ steps.get_filenames.outputs.artifact_name }}
65+
# path: ${{ steps.get_filenames.outputs.exe_name }}

.gitignore

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,3 @@
1-
npm-debug.log
1+
_build/
22
.merlin
3-
yarn-error.log
4-
node_modules
5-
_build
6-
_esy
7-
_release
8-
*.byte
9-
*.native
10-
rescript-react-intl-extractor.install
113
.DS_Store

.vscode/settings.json

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
11
{
2-
"reason.codelens.enabled": true,
3-
"reason.format.width": 120,
4-
"reason_language_server.per_value_codelens": true,
5-
"reason_language_server.format_width": 120,
6-
"editor.rulers": [120],
72
"editor.tabSize": 2,
83
"editor.renderIndentGuides": false,
94
"files.insertFinalNewline": true

bin/dune

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
(executable
2-
(name Extract)
3-
(public_name Extract.exe)
4-
(libraries lib)
5-
)
2+
(name Extract)
3+
(public_name rescript-react-intl-extractor.exe)
4+
(libraries lib))

docker/Dockerfile

Lines changed: 0 additions & 7 deletions
This file was deleted.

docker/README.md

Lines changed: 0 additions & 1 deletion
This file was deleted.

dune-project

Lines changed: 33 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,34 @@
1-
(lang dune 2.0)
1+
(lang dune 2.7)
2+
3+
(name rescript-react-intl-extractor)
4+
5+
(generate_opam_files true)
6+
7+
(license MIT)
8+
9+
(authors "Christoph Knittel <[email protected]>")
10+
11+
(maintainers "Christoph Knittel <[email protected]>")
12+
13+
(source
14+
(github cca-io/rescript-react-intl-extractor))
15+
16+
(bug_reports
17+
"https://github.com/cca-io/rescript-react-intl-extractor/issues")
18+
19+
(homepage "https://github.com/cca-io/rescript-react-intl-extractor")
20+
21+
(documentation "https://github.com/cca-io/rescript-react-intl-extractor")
22+
23+
(package
224
(name rescript-react-intl-extractor)
25+
(synopsis "Extracts messages for localization from ReScript source files")
26+
(depends
27+
(alcotest :with-test)
28+
(ocaml
29+
(= 4.06.1))
30+
(reason
31+
(= 3.7.0))
32+
(yojson
33+
(= 1.7.0))
34+
dune))

esy.lock/.gitattributes

Lines changed: 0 additions & 3 deletions
This file was deleted.

esy.lock/.gitignore

Lines changed: 0 additions & 3 deletions
This file was deleted.

0 commit comments

Comments
 (0)