-
Notifications
You must be signed in to change notification settings - Fork 0
104 lines (91 loc) · 3.32 KB
/
vader-vim-win32.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
---
name: Vader Integration Tests (Win32)
on:
push:
branches: [master]
pull_request:
branches: [master]
workflow_dispatch:
jobs:
build:
runs-on: windows-2019
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Install Vim and Neovim
run: |
choco install -y vim
choco install -y neovim
- name: Download Dependencies
run: |
git clone https://github.com/junegunn/vader.vim.git
Invoke-WebRequest -Uri "https://github.com/rgoulter/c-worksheet-instrumentor/releases/download/v0.2.6/c-worksheet-instrumentor-0.2.6.tar" -OutFile "c-worksheet-instrumentor-0.2.6.tar"
tar -xf c-worksheet-instrumentor-0.2.6.tar
- name: Setup Vim Config init.vim
run: |
$vimrc = @"
set rtp+=vader.vim
set rtp+=.
filetype plugin indent on
" Win32: set .bat
let g:cworksheetify_server_command = "c-worksheetify-server.bat"
"@
$vimrc | Out-File -FilePath init.vim
- name: Demonstrate C Worksheet
run: |
# Uploaded release compiled with recent Java.
$env:JAVA_HOME = $env:JAVA_HOME_21_X64
@"
#include <stdio.h>
int main(int argc, char **argv) {
printf("Hello World\n");
}
"@ | Out-File -FilePath hello.c
./c-worksheet-instrumentor-0.2.6/bin/c-worksheet-instrumentor.bat hello.c
## - name: Test Vim
## run: |
## # Uploaded release compiled with recent Java.
## $env:JAVA_HOME = $env:JAVA_HOME_21_X64
## $env:PATH = "c-worksheet-instrumentor-0.2.6\bin;$env:PATH"
## vim -Es -Nu init.vim -c 'Vader! test\*.vader'
## timeout-minutes: 2
##
## - name: Kill Server
## run: |
## taskkill /im "edu.nus.worksheet.WorksheetifyServer.exe" /f | Out-Null
## Start-Sleep -Seconds 3
##
## - name: Test Vim (with bad c-worksheetify-server)
## run: |
## $env:PATH = "test\bad_server_command;$env:PATH"
## vim -Es -Nu init.vim -c 'Vader! test/bad_server_command/*.vader'
## timeout-minutes: 2
##
## - name: Test Vim (with c-worksheetify-server not on PATH)
## run: |
## vim -Es -Nu init.vim -c 'Vader! test/command_not_found/*.vader'
## timeout-minutes: 2
- name: Test NeoVim
run: |
# Uploaded release compiled with recent Java.
C:\tools\nvim -version
nvim -version
$env:JAVA_HOME = $env:JAVA_HOME_21_X64
$env:PATH = "c-worksheet-instrumentor-0.2.6\bin;$env:PATH"
nvim -Es -u init.vim -c 'Vader! test/*.vader'
timeout-minutes: 2
- name: Kill Server
run: |
taskkill /im "edu.nus.worksheet.WorksheetifyServer.exe" /f | Out-Null
Start-Sleep -Seconds 3
- name: Test NeoVim (with bad c-worksheetify-server)
run: |
$env:PATH = "test\bad_server_command;$env:PATH"
nvim -Es -u init.vim -c 'Vader! test/bad_server_command/*.vader'
timeout-minutes: 2
- name: Test NeoVim (with bad c-worksheetify-server)
run: |
$env:PATH = "test\bad_server_command;$env:PATH"
nvim -Es -u init.vim -c 'Vader! test/bad_server_command/*.vader'
timeout-minutes: 2