Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
281 commits
Select commit Hold shift + click to select a range
abef46e
simplified podman service - ready for testing
davidlday Sep 24, 2022
1b7eff1
implemented managed service
davidlday Sep 24, 2022
7ce4d13
use constant for configuration root
davidlday Sep 24, 2022
cfd8ef1
checking in, but still working out new tests
davidlday Sep 24, 2022
97fc488
added service state
davidlday Sep 24, 2022
3372765
added public service tests
davidlday Sep 24, 2022
687ab1e
added service states
davidlday Sep 24, 2022
23d0997
removed unused document
davidlday Sep 24, 2022
2dd323d
added LT config items
davidlday Sep 24, 2022
bf111a0
cleand up imports
davidlday Sep 24, 2022
c597588
publicservice tests passing
davidlday Sep 24, 2022
1199040
putting all service tests together
davidlday Sep 24, 2022
ab147e2
fixed types
davidlday Sep 25, 2022
3ac32ec
removed extra ".podman"
davidlday Sep 25, 2022
a69bcb5
split service tests again for clarity
davidlday Sep 25, 2022
419dd6c
check state on invokeLanguageTool
davidlday Sep 25, 2022
12e7fbc
removed state check
davidlday Sep 25, 2022
8bf1f43
semi-functional podman
davidlday Sep 25, 2022
3f44d74
added external service tests
davidlday Sep 25, 2022
679e63e
reset podman command to just podman
davidlday Sep 25, 2022
b38e1d2
renamed tests to align with other test names
davidlday Sep 25, 2022
596e27c
added hard stop config
davidlday Sep 25, 2022
d680b74
added hard stop config
davidlday Sep 25, 2022
b1b94f9
ping tests for service state before pinging
davidlday Sep 25, 2022
e01f969
fixed url
davidlday Sep 25, 2022
8f042a1
podman tests passing!
davidlday Sep 25, 2022
90710f8
added notes for LT Premium Access and podman service
davidlday Sep 25, 2022
f632bd2
use homebrew on mac to install podman
davidlday Sep 25, 2022
6691619
return boolena on stop and ping
davidlday Sep 25, 2022
b3a625d
organized imports and return boolean on ping and stop
davidlday Sep 25, 2022
8b4f0cf
leverage podman to test external service
davidlday Sep 25, 2022
02b275b
return boolean on ping and stop
davidlday Sep 25, 2022
16e9c71
return boolean on stop
davidlday Sep 25, 2022
cdbfbd9
run podman machine on init
davidlday Sep 25, 2022
d8ec2ed
hard stop podman by default
davidlday Sep 25, 2022
afdcacc
use homebrew on ubuntu for podman
davidlday Sep 25, 2022
820196c
setup podman and lt on windows using choco
davidlday Sep 25, 2022
1cb3c49
separated podman init and start, fixed choco installs
davidlday Sep 25, 2022
76597ff
use apt on ubuntu, winget on windows
davidlday Sep 25, 2022
9cc0f48
try scoop on windows
davidlday Sep 25, 2022
8aca5d5
manually install podman on windows
davidlday Sep 25, 2022
a508343
increased timeout for podman to start
davidlday Sep 25, 2022
1e1b775
updated push
davidlday Sep 25, 2022
004019b
trying apt again
davidlday Sep 25, 2022
e99aec0
added install for qemu
davidlday Sep 25, 2022
ab75211
debugging podman
davidlday Sep 25, 2022
4def184
trying right qemu command
davidlday Sep 25, 2022
ae87067
trying specific qemu package
davidlday Sep 26, 2022
64c031d
manually pull gvproxy
davidlday Sep 26, 2022
78edaa0
duh - don't need podman machine on linux
davidlday Sep 26, 2022
7217c56
skip podman machine on linux
davidlday Sep 26, 2022
1ef8ad6
removed unused code
davidlday Sep 26, 2022
866be60
try installing homebrew
davidlday Sep 26, 2022
ce18b03
remove lt from apt install
davidlday Sep 26, 2022
fc66ee9
direct download lt
davidlday Sep 26, 2022
ef60778
need to cd into directory
davidlday Sep 26, 2022
abedc3c
specify LT version
davidlday Sep 26, 2022
d2fc564
unzip 5.8
davidlday Sep 26, 2022
81c5f9a
ugh - more directory typos
davidlday Sep 26, 2022
40e6556
just need to move on for now
davidlday Sep 26, 2022
a2d3d87
updated config-array
davidlday Sep 26, 2022
7abbb89
specify dir in unzip
davidlday Sep 26, 2022
5cfdde2
more trying to get LT to run
davidlday Sep 26, 2022
e3daad9
finding path for LT
davidlday Sep 26, 2022
8139d7f
extended startup timeouts for podman
davidlday Sep 26, 2022
61c8a04
reinstate all tests
davidlday Sep 26, 2022
9031cf8
set timeout to 50000
davidlday Sep 27, 2022
9324ca5
added podman health and status consts
davidlday Sep 27, 2022
e02c989
renamed running state to ready state
davidlday Sep 27, 2022
12cd95e
added health check to ensure container is ready
davidlday Sep 27, 2022
04a2ca6
bumped timeout to 10000 for podman on first run
davidlday Sep 27, 2022
fec768c
renamed ready state to running state
davidlday Sep 27, 2022
2b2ae23
renamed running state to ready state
davidlday Sep 27, 2022
5798f93
pre-pull lt image
davidlday Sep 27, 2022
10447c7
pre-warm podman service
davidlday Sep 27, 2022
04f4aed
boosted timeout again
davidlday Sep 27, 2022
cc55963
more attempts to get podman running in gh actions
davidlday Sep 28, 2022
d55acc9
added github-actions
davidlday Sep 28, 2022
377cabf
added DBUS_SESSION_BUS_ADDRESS
davidlday Sep 28, 2022
a655fdd
reduced timeout
davidlday Sep 28, 2022
f8e8fa9
make necessary dirs
davidlday Sep 28, 2022
c19610a
extend timeout
davidlday Sep 28, 2022
88139eb
apparently DON'T make the bus dir
davidlday Sep 28, 2022
50ded67
better dependency checking on podman states
davidlday Sep 28, 2022
868f10a
fleshed out error handling
davidlday Sep 28, 2022
3cb2c70
fixed typo
davidlday Sep 28, 2022
7748ba6
added more error catching
davidlday Sep 29, 2022
61b60ba
use podman 4.x from Kubic
davidlday Sep 30, 2022
e2824f0
added try/catch to isContainerHealthy
davidlday Sep 30, 2022
4c3089a
removed -qq from apt-get
davidlday Sep 30, 2022
29be4fc
test for health status, not just container
davidlday Sep 30, 2022
dfa0ba6
remove podman and buildah first
davidlday Sep 30, 2022
2524404
upgrade podman, duh
davidlday Sep 30, 2022
912c181
reverted to purge / install of podman
davidlday Sep 30, 2022
96069e3
use ubuntu 22.04
davidlday Sep 30, 2022
825ce5d
commented out PodmanMachine interface
davidlday Sep 30, 2022
43a7490
log out the URL
davidlday Sep 30, 2022
db396d7
updated ubuntu runner
davidlday Sep 30, 2022
8f1d220
use ip / port vars as fallback
davidlday Sep 30, 2022
10808a5
updated mac job based on ubuntu
davidlday Sep 30, 2022
a5817c8
don't mkdir
davidlday Sep 30, 2022
b230b57
skip using XDG_RUNTIME_DIR
davidlday Sep 30, 2022
9823be3
use msiexec on windows
davidlday Sep 30, 2022
5be519b
set ip address on podman start
davidlday Sep 30, 2022
9209a0e
removed unused steps, silent install on windows
davidlday Sep 30, 2022
f1835a5
specify path on windows
davidlday Sep 30, 2022
3770425
log installer
davidlday Sep 30, 2022
e67640d
remove url logging
davidlday Sep 30, 2022
39adffd
podman admin install
davidlday Sep 30, 2022
9ac9395
try using scoop
davidlday Sep 30, 2022
e99e191
run scoop install as admin
davidlday Sep 30, 2022
a30ec58
manually add scoop to the path
davidlday Sep 30, 2022
0b91538
bump path above scoop
davidlday Sep 30, 2022
edec33c
remove trailing slash
davidlday Sep 30, 2022
651844f
use tilda
davidlday Sep 30, 2022
c2590a2
auto start LxssManager
davidlday Sep 30, 2022
f919b58
manually start wsl
davidlday Oct 1, 2022
5fcf975
added setup-wsl
davidlday Oct 1, 2022
45724fe
focus on mac build w/ podman
davidlday Oct 1, 2022
bf539e7
cleaned up code.
davidlday Oct 1, 2022
bdc5985
reusable ubuntu build
davidlday Oct 1, 2022
922e330
remove podman version
davidlday Oct 1, 2022
819591f
quick podman health check before running tests
davidlday Oct 1, 2022
9235f7b
leverage healthcheck
davidlday Oct 1, 2022
e9c2fcd
renamed called job
davidlday Oct 2, 2022
1d0fc80
increase timeout on external ping
davidlday Oct 2, 2022
1754f46
moved builds/ubuntu.yaml to build-ubuntu.yaml
davidlday Oct 2, 2022
8ed20e5
increase timeout for after
davidlday Oct 2, 2022
3db038a
added workspace to launch configurations
davidlday Oct 2, 2022
86f4df3
Moved Managed Service out of config manager.
davidlday Oct 2, 2022
e63a17b
add one second on startup.
davidlday Oct 2, 2022
4079f37
Linter calls service for LT
davidlday Oct 2, 2022
16ffec3
added service config root and username/apikey to services
davidlday Oct 2, 2022
e97472b
added service config root
davidlday Oct 2, 2022
4409c63
added public configurations
davidlday Oct 2, 2022
fda992c
simplified configuration manager tests
davidlday Oct 2, 2022
a64d91d
added public service configurations
davidlday Oct 2, 2022
023d7e7
reinstated managed service tests
davidlday Oct 2, 2022
18901ab
added podman command and deprecation messages
davidlday Oct 2, 2022
c357cf5
added podman command
davidlday Oct 2, 2022
53e6216
added podman command
davidlday Oct 2, 2022
755b91d
fixed job name
davidlday Oct 2, 2022
5397669
using environment variables to set test configuration
davidlday Oct 3, 2022
ec2a33d
updated to vscode/test-electron
davidlday Oct 3, 2022
e6fff24
updated testing
davidlday Oct 3, 2022
8cc2d72
removed unused code
davidlday Oct 3, 2022
a96e2f5
removed async
davidlday Oct 3, 2022
dafca85
fixed activation test
davidlday Oct 7, 2022
c13b625
separated out service tests
davidlday Oct 8, 2022
a7494ef
added testing env variables
davidlday Oct 8, 2022
0e219d2
removed name from workflow call
davidlday Oct 8, 2022
46ef7aa
quoting reusable workflow
davidlday Oct 8, 2022
64b232e
yaml -> yml
davidlday Oct 8, 2022
01ba402
removed reusable workflows
davidlday Oct 8, 2022
7a868f3
Merge branch 'master' into podman
davidlday Oct 8, 2022
1825395
podman machine start w/defaults.
davidlday Oct 8, 2022
a39f2d7
disable gpu on tests
davidlday Oct 8, 2022
1bbfe11
merged changes into master
davidlday Oct 8, 2022
09bf157
tweaking xvfb settings
davidlday Oct 8, 2022
be426ea
cat out the xsession.log
davidlday Oct 9, 2022
b2b6728
removed cat xsession.log
davidlday Oct 9, 2022
3f224e8
disable extensions
davidlday Nov 3, 2022
15be2a0
use public lt service as external
davidlday Nov 3, 2022
958e3a6
revert to ubuntu 20.04
davidlday Nov 3, 2022
35bdc54
fixed up ManageService
davidlday Nov 4, 2022
fadab5e
reinstated managed service tests
davidlday Nov 4, 2022
cf113e0
use public api for external testing
davidlday Nov 4, 2022
87f05d1
Merge branch 'master' into podman
davidlday Nov 4, 2022
7637b43
Merge branch 'podman' of github.com:davidlday/vscode-languagetool-lin…
davidlday Nov 4, 2022
14738b0
just installing some more stuff
davidlday Nov 4, 2022
35cd0cd
mostly functional tests
davidlday Nov 5, 2022
2d629bd
use correct pipeline
davidlday Nov 5, 2022
a603942
start dbus
davidlday Nov 5, 2022
a356145
restored "install stuff"
davidlday Nov 5, 2022
07403c7
install lt via homebrew
davidlday Nov 5, 2022
b949c1e
add brew to path
davidlday Nov 5, 2022
00a6e91
added concurrency
davidlday Nov 5, 2022
889b177
start lt for external tests
davidlday Nov 5, 2022
1906d7a
removed build-ubuntu
davidlday Nov 5, 2022
d6c0557
try brew podman
davidlday Nov 5, 2022
eaefb69
added npm caching
davidlday Nov 5, 2022
d26672c
fixed duplicate id
davidlday Nov 5, 2022
c2d5aca
implementing homebrew caching
davidlday Nov 5, 2022
ca77716
cache linuxbrew
davidlday Nov 5, 2022
6020341
do all brew intalls at once
davidlday Nov 5, 2022
c506816
start services on test step
davidlday Nov 5, 2022
d529f3c
remove old podman
davidlday Nov 5, 2022
ddc9129
ignore direnv's .envc
davidlday Nov 5, 2022
da7714d
push homebrew vars into environment
davidlday Nov 5, 2022
6b112dc
restored npm test
davidlday Nov 5, 2022
464628c
Merge branch 'master' into podman
davidlday Nov 5, 2022
08a4a5c
cleanup and check svcs before test
davidlday Nov 5, 2022
8130a99
returned all tests to suite
davidlday Nov 5, 2022
f84d44a
fixed extension activation and commands tests
davidlday Nov 5, 2022
15951b1
elimiated podman-specific reloadConfiguration
davidlday Nov 5, 2022
dab0fa3
reloadConfiguration also returns Promise<boolean>
davidlday Nov 5, 2022
a12df58
use chai and chai-as-promised in service tests
davidlday Nov 5, 2022
3929abe
fixed podman container name
davidlday Nov 5, 2022
d785b3c
use brew services and test external on port 8081
davidlday Nov 5, 2022
62a244e
list brew services
davidlday Nov 6, 2022
2b87435
removed unused imports
davidlday Nov 6, 2022
ff9a07c
fixed brew services start
davidlday Nov 6, 2022
9a27d6a
add curl checks to service starts
davidlday Nov 6, 2022
b3280c2
podman restart and version check
davidlday Nov 6, 2022
b1f9845
list out services
davidlday Nov 6, 2022
6ee4629
use homebrew setup action
davidlday Nov 6, 2022
7c422aa
start services early
davidlday Nov 6, 2022
89fb9ce
cat ltserver log
davidlday Nov 6, 2022
9b533e5
check log twice
davidlday Nov 6, 2022
4e4ca60
no start, no log!
davidlday Nov 6, 2022
2be5476
do a little healthcheck before curls
davidlday Nov 6, 2022
86bce18
sleep longer for podman
davidlday Nov 6, 2022
787fc0c
use podman for external and test state
davidlday Nov 6, 2022
4350c09
removed sudo
davidlday Nov 6, 2022
700b7e8
removed extra podman commands
davidlday Nov 6, 2022
752158c
update image tag and remove curls
davidlday Nov 7, 2022
beebded
update image tag and removed commented code
davidlday Nov 7, 2022
b7d4120
still trying to get podman services running
davidlday Nov 7, 2022
c986b15
implemented better health checking
davidlday Nov 7, 2022
b3c5cb6
check result of start
davidlday Nov 7, 2022
a90fec4
fixed spelling of Health
davidlday Nov 7, 2022
e834538
set image to 5.9
davidlday Nov 7, 2022
0c4a3f7
removed imageName, use default
davidlday Nov 7, 2022
c76af9a
5.8 -> 5.9
davidlday Nov 7, 2022
a314316
consolidated test steps into a single step
davidlday Nov 7, 2022
5b3b2aa
fixed missing container names
davidlday Nov 7, 2022
1e70c36
added check for both containers
davidlday Nov 7, 2022
9d76b07
removed old block for testing services
davidlday Nov 8, 2022
825b708
increase ping timeout for mac runner
davidlday Nov 8, 2022
d25f714
fixed state checks
davidlday Nov 8, 2022
923612e
specify 127.0.0.1 for podman and external tests
davidlday Nov 8, 2022
59e4862
extended ping timeout for mac runner
davidlday Nov 9, 2022
ada862c
fix: check both container status and health
davidlday Nov 29, 2022
e022649
chore: removed unused import
davidlday Nov 29, 2022
a1be12e
chore: execa 5.1.1
davidlday Nov 29, 2022
0ea4402
chore: check service state on lint
davidlday Nov 29, 2022
bbf5ec4
chore: permit unhealthy during startup
davidlday Nov 29, 2022
4235758
chore: functional managedservice
davidlday Nov 29, 2022
6bcdcbf
chore: reinstated tests for managed service
davidlday Nov 29, 2022
d618f05
chore: removed build on ubuntu
davidlday Dec 5, 2022
f419af4
chore: removed commented out code
davidlday Dec 5, 2022
9f1e476
chore: refined state checks
davidlday Dec 5, 2022
dede7d0
chore: override getState()
davidlday Dec 5, 2022
37e21aa
chore: testing with "sleep"
davidlday Dec 5, 2022
e484d49
Merge branch 'master' into podman
davidlday Dec 6, 2022
4ca285b
chore: setup-node v3
davidlday Dec 8, 2022
346ff35
chore: setup node v3
davidlday Dec 8, 2022
32ea1bf
chore: setup node @v3.5.1
davidlday Dec 8, 2022
a653261
initial version of homebrew service
davidlday Apr 2, 2023
337adfd
removed unused import
davidlday Jul 25, 2023
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
85 changes: 72 additions & 13 deletions .github/workflows/nodejs-ci-push.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,25 +7,84 @@ concurrency:
cancel-in-progress: true

jobs:
# call-workflow-build-ubuntu:
# uses: ./.github/worklows/build-ubuntu.yml
ubuntu-build:
runs-on: ubuntu-latest
runs-on: ubuntu-22.04
name: Build on Ubuntu
env:
DISPLAY: ":99.0"
CI: true
steps:
- uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: lts/*
- run: /usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
name: Start Xvfb
- run: npm install -g typescript vsce json
- run: npm ci
- run: npm run vscode:prepublish
- run: npm run test-compile
- run: npm test
name: Test
- run: npm run lint
name: ESLint
cache: "npm"
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: Cache Homebrew
id: cache-homebrew
uses: actions/cache@v3
with:
path: /home/runner/.cache/Homebrew
key: ${{ runner.os }}-homebrew
- name: Set Test Environment Variables
id: set-test-environment-variables
run: |
echo "LTLINTER_MANAGED_CLASSPATH=/usr/local/opt/languagetool/libexec/languagetool-server.jar" >> $GITHUB_ENV
echo "LTLINTER_TEST_SERVICES=true" >> $GITHUB_ENV
LTLINTER_IMAGE=$(cat ./package.json | jq -r '.contributes.configuration.properties."languageToolLinter.podman.imageName".default')
echo "LTLINTER_IMAGE=$LTLINTER_IMAGE" >> $GITHUB_ENV
- name: Start Xvfb
id: start-xvfb
run: |
/usr/bin/Xvfb :99 -screen 0 1024x768x24 +extension GLX +render -noreset >> $HOME/xsession.log 2>&1 &
- name: Enable Linger for Podman
id: enable-linger
run: |
loginctl enable-linger $(whoami)
sleep 1
- name: Set XDG_RUNTIME_DIR
id: set-xdg_runtime_dir
run: |
echo "XDG_RUNTIME_DIR=/run/user/$UID" >> $GITHUB_ENV
echo "DBUS_SESSION_BUS_ADDRESS=unix:path=/run/user/$UID/bus" >> $GITHUB_ENV
- name: Install Podman, and Languagetool
id: install-brew-podman
run: |
sudo apt-get purge podman buildah
brew install podman languagetool jq
brew services restart podman
- name: Start LT Podman Services
id: start-lt-podman-service
run: |
podman version
podman pull $LTLINTER_IMAGE
podman run -d -p 127.0.0.1:8082:8010 --name languagetool-test $LTLINTER_IMAGE
podman run -d -p 127.0.0.1:8081:8010 --name languagetool-external $LTLINTER_IMAGE
teststate=$(podman inspect languagetool-test|jq -r '.[0].State.Health.Status')
echo "State: $teststate"
while [ "$teststate" != "healthy" ]; do
echo "State: $teststate"
sleep 1
teststate=$(podman inspect languagetool-test|jq -r '.[0].State.Health.Status')
done;
extstate=$(podman inspect languagetool-external|jq -r '.[0].State.Health.Status')
echo "State: $extstate"
while [ "$extstate" != "healthy" ]; do
echo "State: $extstate"
sleep 1
extstate=$(podman inspect languagetool-external|jq -r '.[0].State.Health.Status')
done;
- name: Run Tests
run: |
podman ps -a
npm run clean
npm install -g typescript vsce json
npm ci
npm run vscode:prepublish
npm test
- name: ESLint
run: npm run lint
172 changes: 116 additions & 56 deletions .github/workflows/nodejs-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,69 +7,129 @@ concurrency:
cancel-in-progress: true

jobs:
ubuntu-build:
runs-on: ubuntu-latest
name: Build on Ubuntu
env:
DISPLAY: ":99.0"
CI: true
steps:
- uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/[email protected]
with:
node-version: lts/*
- run: /usr/bin/Xvfb :99 -screen 0 1024x768x24 > /dev/null 2>&1 &
name: Start Xvfb
- run: npm install -g typescript vsce json
- run: npm ci
- run: npm run vscode:prepublish
- run: npm run test-compile
- run: npm test
name: Test
- run: npm run lint
name: ESLint

macos-build:
runs-on: macos-latest
name: Build on MacOS
env:
CI: true
steps:
- uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/[email protected]
- uses: actions/[email protected]
with:
node-version: lts/*
- run: npm install -g typescript vsce json
- run: npm ci
- run: npm run vscode:prepublish
- run: npm run test-compile
- run: npm test
name: Test
- run: npm run lint
name: ESLint

windows-build:
runs-on: windows-latest
name: Build on Windows
env:
CI: true
steps:
- name: Set git to use LF
run: |
git config --global core.autocrlf false
git config --global core.eol lf
- uses: actions/checkout@v3
- name: Setup Node.js
uses: actions/[email protected]
cache: "npm"
- name: Set up Homebrew
id: set-up-homebrew
uses: Homebrew/actions/setup-homebrew@master
- name: Cache Homebrew
id: cache-homebrew
uses: actions/cache@v3
with:
node-version: lts/*
- run: npm install -g typescript vsce json
- run: npm ci
- run: npm run vscode:prepublish
- run: npm run test-compile
- run: npm test
name: Test
- run: npm run lint
name: ESLint
path: ~/Library/Caches/Homebrew
key: ${{ runner.os }}-homebrew
- name: Set Test Environment Variables
id: set-test-environment-variables
run: |
echo "LTLINTER_MANAGED_CLASSPATH=/usr/local/opt/languagetool/libexec/languagetool-server.jar" >> $GITHUB_ENV
echo "LTLINTER_TEST_SERVICES=true" >> $GITHUB_ENV
LTLINTER_IMAGE=$(cat ./package.json | jq -r '.contributes.configuration.properties."languageToolLinter.podman.imageName".default')
echo "LTLINTER_IMAGE=$LTLINTER_IMAGE" >> $GITHUB_ENV
- name: Install Podman and Languagetool
id: install-brew
run: |
brew install podman languagetool
- name: Initialize Podman Machine
id: initialize-podman-machine
run: podman machine init
- name: Start Podman Machine
id: start-podman-machine
run: |
sudo /usr/local/opt/podman/bin/podman-mac-helper install
brew services restart podman
podman machine start
- name: Start LT Podman Services
id: start-lt-podman-service
run: |
podman version
podman pull $LTLINTER_IMAGE
podman run -d -p 127.0.0.1:8082:8010 --name languagetool-test $LTLINTER_IMAGE
podman run -d -p 127.0.0.1:8081:8010 --name languagetool-external $LTLINTER_IMAGE
teststate=$(podman inspect languagetool-test|jq -r '.[0].State.Health.Status')
echo "State: $teststate"
while [ "$teststate" != "healthy" ]; do
echo "State: $teststate"
sleep 1
teststate=$(podman inspect languagetool-test|jq -r '.[0].State.Health.Status')
done;
extstate=$(podman inspect languagetool-external|jq -r '.[0].State.Health.Status')
echo "State: $extstate"
while [ "$extstate" != "healthy" ]; do
echo "State: $extstate"
sleep 1
extstate=$(podman inspect languagetool-external|jq -r '.[0].State.Health.Status')
done;
- name: Run Tests
run: |
podman ps -a
npm run clean
npm install -g typescript vsce json
npm ci
npm run vscode:prepublish
npm test
- name: ESLint
run: npm run lint

# windows-build:
# runs-on: windows-latest
# name: Build on Windows
# env:
# CI: true
# steps:
# - name: Set git to use LF
# run: |
# git config --global core.autocrlf false
# git config --global core.eol lf
# - uses: actions/checkout@v3
# - uses: actions/setup-node@v3
# with:
# node-version: lts/*
# - uses: Vampire/setup-wsl@v1
# - name: Append scoop shims to path
# run: |
# echo "~\scoop\shims" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
# - name: Install Podman via Scoop
# id: install-podman-via-scoop
# run: |
# Set-ExecutionPolicy RemoteSigned -Scope CurrentUser
# iex "& {$(irm get.scoop.sh)} -RunAsAdmin"
# scoop install podman
# # - name: Download Podman Installer
# # id: download-podman
# # run:
# # Invoke-WebRequest
# # https://github.com/containers/podman/releases/download/v4.2.1/podman-v4.2.1.msi
# # -o "D:\a\vscode-languagetool-linter\podman-v4.2.1.msi"
# # - name: Install Podman
# # id: install-podman
# # run: |
# # msiexec /a "D:\a\vscode-languagetool-linter\podman-v4.2.1.msi" /passive /log "D:\a\vscode-languagetool-linter\podman.log"
# # type "D:\a\vscode-languagetool-linter\podman.log"
# - name: Initialize Podman Machine
# id: initialize-podman-machine
# run: |
# wsl -l -v
# podman machine init
# - name: Start Podman Machine
# id: start-podman-machine
# run: podman machine start
# - name: Install LanguageTool
# id: install-languagetool
# run: choco install languagetool
# - run: npm install -g typescript vsce json
# - run: npm ci
# - run: npm run vscode:prepublish
# - run: npm run test-compile
# - run: npm test
# name: Test
# - run: npm run lint
# name: ESLint
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,6 @@ out

# Webpack Directory
dist/

# direnv
.envrc
9 changes: 7 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@
"type": "extensionHost",
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": ["--extensionDevelopmentPath=${workspaceFolder}"],
"args": [
"${workspaceFolder}/test-fixtures/workspace",
"--extensionDevelopmentPath=${workspaceFolder}"
],
"outFiles": ["${workspaceFolder}/dist/**/*.js"],
"preLaunchTask": "npm: webpack"
},
Expand All @@ -20,8 +23,10 @@
"request": "launch",
"runtimeExecutable": "${execPath}",
"args": [
"${workspaceFolder}/test-fixtures/workspace",
"--extensionDevelopmentPath=${workspaceFolder}",
"--extensionTestsPath=${workspaceFolder}/out/test/suite/index"
"--extensionTestsPath=${workspaceFolder}/out/test/suite/index",
"--disable-gpu"
],
"outFiles": ["${workspaceFolder}/out/test/**/*.js"],
"preLaunchTask": "npm: test-compile",
Expand Down
71 changes: 36 additions & 35 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,38 +1,39 @@
// Place your settings in this file to overwrite default and user settings.
{
"markdownlint.config": {
"MD013": false,
"MD024": false
},
"files.exclude": {
"out": false // set this to true to hide the "out" folder with the compiled JS files
},
"search.exclude": {
"out": true // set this to false to include "out" folder in search results
},
// Turn off tsc task auto detection since we have the necessary tasks as npm scripts
"typescript.tsc.autoDetect": "off",
"languageToolLinter.languageTool.ignoredWordsInWorkspace": [
"annotatedtext",
"annotatedtext-remark",
"api",
"codacy",
"de-at",
"de-de",
"globbing",
"http-proxy-agent",
"languagetool-linter",
"linter",
"localhost",
"lt<sub>e</sub>x",
"npmjs",
"pacman",
"plaintext",
"socio-economic",
"tslint",
"voss",
"webpack",
"yaml"
],
"languageToolLinter.languageTool.disabledRules": "DASH_RULE"
"markdownlint.config": {
"MD013": false,
"MD024": false
},
"files.exclude": {
"out": false // set this to true to hide the "out" folder with the compiled JS files
},
"search.exclude": {
"out": true // set this to false to include "out" folder in search results
},
// Turn off tsc task auto detection since we have the necessary tasks as npm scripts
"typescript.tsc.autoDetect": "off",
"languageToolLinter.languageTool.ignoredWordsInWorkspace": [
"annotatedtext",
"annotatedtext-remark",
"api",
"codacy",
"de-at",
"de-de",
"globbing",
"http-proxy-agent",
"languagetool-linter",
"linter",
"localhost",
"lt<sub>e</sub>x",
"npmjs",
"pacman",
"plaintext",
"socio-economic",
"tslint",
"voss",
"webpack",
"yaml"
],
"languageToolLinter.languageTool.disabledRules": "DASH_RULE",
"languageToolLinter.external.url": "http://localhost:8010"
}
Loading