Skip to content

Commit bac858f

Browse files
committed
[workflow] Testing github workflow
1 parent e8a2043 commit bac858f

File tree

4 files changed

+148
-19
lines changed

4 files changed

+148
-19
lines changed

.github/workflows/test_pymode.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Testing python-mode
2+
3+
on: [push]
4+
5+
jobs:
6+
test-python-3_6:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
- name: Install dependencies
11+
run: |
12+
sudo apt update
13+
sudo apt install -yqq libncurses5-dev libatk1.0-dev python-dev python3-dev lua5.1 lua5.1-dev libperl-dev git
14+
sudo apt remove --purge vim vim-runtime gvim
15+
- name: build and install vim from source
16+
working-directory: /tmp
17+
run: |
18+
git clone https://github.com/vim/vim.git
19+
cd vim
20+
./configure --with-features=huge --enable-multibyte --enable-python3interp=yes --with-python3-config-dir=/usr/lib/python3.6/config-3.6m-x86_64-linux-gnu --enable-perlinterp=yes --enable-luainterp=yes --enable-cscope --prefix=/usr/local
21+
sudo make && sudo make install
22+
- name: Install python-mode
23+
run: |
24+
export PYMODE_DIR="${HOME}/work/python-mode/python-mode"
25+
mkdir -p ${HOME}/.vim/pack/foo/start/
26+
ln -s ${PYMODE_DIR} ${HOME}/.vim/pack/foo/start/python-mode
27+
cp ${PYMODE_DIR}/tests/utils/pymoderc ${HOME}/.pymoderc
28+
cp ${PYMODE_DIR}/tests/utils/vimrc ${HOME}/.vimrc
29+
touch ${HOME}/.vimrc.before ${HOME}/.vimrc.after
30+
- name: Run python-mode test script
31+
run: |
32+
alias python=python3
33+
cd ${HOME}/work/python-mode/python-mode
34+
git submodule update --init --recursive
35+
git submodule sync
36+
bash tests/test.sh

.travis.yml

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

tests/utils/pymoderc

Lines changed: 90 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,90 @@
1+
" These are all pymode configs. You can read about them using :help pymode
2+
let g:pymode = 1
3+
let g:pymode_warnings = 1
4+
let g:pymode_paths = []
5+
let g:pymode_trim_whitespaces = 1
6+
let g:pymode_options = 1
7+
let g:pymode_options_max_line_length = 79
8+
let g:pymode_options_colorcolumn = 1
9+
let g:pymode_quickfix_minheight = 3
10+
let g:pymode_quickfix_maxheight = 6
11+
let g:pymode_indent = 1
12+
let g:pymode_folding = 0
13+
let g:pymode_motion = 1
14+
let g:pymode_doc = 1
15+
let g:pymode_doc_bind = 'K'
16+
let g:pymode_virtualenv = 1
17+
let g:pymode_virtualenv_path = $VIRTUAL_ENV
18+
let g:pymode_run = 1
19+
let g:pymode_run_bind = '<leader>r'
20+
let g:pymode_breakpoint = 1
21+
let g:pymode_breakpoint_bind = '<leader>b'
22+
let g:pymode_breakpoint_cmd = ''
23+
let g:pymode_lint = 1
24+
let g:pymode_lint_on_write = 1
25+
let g:pymode_lint_unmodified = 0
26+
let g:pymode_lint_on_fly = 0
27+
let g:pymode_lint_message = 1
28+
let g:pymode_lint_checkers = ['pyflakes', 'pep8', 'mccabe']
29+
let g:pymode_lint_ignore = ["E501", "W",]
30+
let g:pymode_lint_select = ["E501", "W0011", "W430"]
31+
let g:pymode_lint_sort = []
32+
let g:pymode_lint_cwindow = 1
33+
let g:pymode_lint_signs = 1
34+
let g:pymode_lint_todo_symbol = 'WW'
35+
let g:pymode_lint_comment_symbol = 'CC'
36+
let g:pymode_lint_visual_symbol = 'RR'
37+
let g:pymode_lint_error_symbol = 'EE'
38+
let g:pymode_lint_info_symbol = 'II'
39+
let g:pymode_lint_pyflakes_symbol = 'FF'
40+
let g:pymode_lint_options_pep8 =
41+
\ {'max_line_length': g:pymode_options_max_line_length}
42+
let g:pymode_lint_options_pyflakes = { 'builtins': '_' }
43+
let g:pymode_lint_options_mccabe = { 'complexity': 12 }
44+
let g:pymode_lint_options_pep257 = {}
45+
let g:pymode_lint_options_pylint =
46+
\ {'max-line-length': g:pymode_options_max_line_length}
47+
let g:pymode_rope = 1
48+
let g:pymode_rope_lookup_project = 0
49+
let g:pymode_rope_project_root = ""
50+
let g:pymode_rope_ropefolder='.ropeproject'
51+
let g:pymode_rope_show_doc_bind = '<C-c>d'
52+
let g:pymode_rope_regenerate_on_write = 1
53+
let g:pymode_rope_completion = 1
54+
let g:pymode_rope_complete_on_dot = 1
55+
let g:pymode_rope_completion_bind = '<C-Space>'
56+
let g:pymode_rope_autoimport = 0
57+
let g:pymode_rope_autoimport_modules = ['os', 'shutil', 'datetime']
58+
let g:pymode_rope_autoimport_import_after_complete = 0
59+
let g:pymode_rope_goto_definition_bind = '<C-c>g'
60+
let g:pymode_rope_goto_definition_cmd = 'new'
61+
let g:pymode_rope_rename_bind = '<C-c>rr'
62+
let g:pymode_rope_rename_module_bind = '<C-c>r1r'
63+
let g:pymode_rope_organize_imports_bind = '<C-c>ro'
64+
let g:pymode_rope_autoimport_bind = '<C-c>ra'
65+
let g:pymode_rope_module_to_package_bind = '<C-c>r1p'
66+
let g:pymode_rope_extract_method_bind = '<C-c>rm'
67+
let g:pymode_rope_extract_variable_bind = '<C-c>rl'
68+
let g:pymode_rope_use_function_bind = '<C-c>ru'
69+
let g:pymode_rope_move_bind = '<C-c>rv'
70+
let g:pymode_rope_change_signature_bind = '<C-c>rs'
71+
let g:pymode_syntax = 1
72+
let g:pymode_syntax_slow_sync = 1
73+
let g:pymode_syntax_all = 1
74+
let g:pymode_syntax_print_as_function = 0
75+
let g:pymode_syntax_highlight_async_await = g:pymode_syntax_all
76+
let g:pymode_syntax_highlight_equal_operator = g:pymode_syntax_all
77+
let g:pymode_syntax_highlight_stars_operator = g:pymode_syntax_all
78+
let g:pymode_syntax_highlight_self = g:pymode_syntax_all
79+
let g:pymode_syntax_indent_errors = g:pymode_syntax_all
80+
let g:pymode_syntax_space_errors = g:pymode_syntax_all
81+
let g:pymode_syntax_string_formatting = g:pymode_syntax_all
82+
let g:pymode_syntax_string_format = g:pymode_syntax_all
83+
let g:pymode_syntax_string_templates = g:pymode_syntax_all
84+
let g:pymode_syntax_doctests = g:pymode_syntax_all
85+
let g:pymode_syntax_builtin_objs = g:pymode_syntax_all
86+
let g:pymode_syntax_builtin_types = g:pymode_syntax_all
87+
let g:pymode_syntax_highlight_exceptions = g:pymode_syntax_all
88+
let g:pymode_syntax_docstrings = g:pymode_syntax_all
89+
90+
" vim:tw=79:ts=8:ft=help:norl:

tests/utils/vimrc

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
source /root/.vimrc.before
2+
source /root/.pymoderc
3+
4+
syntax on
5+
filetype plugin indent on
6+
set shortmess=at
7+
set cmdheight=10
8+
set ft=python
9+
set shell=bash
10+
set rtp+=/root/.vim/pack/foo/start/python-mode
11+
set term=xterm-256color
12+
set wrap " visually wrap lines
13+
set smartindent " smart indenting
14+
set shiftwidth=4 " default to two spaces
15+
set tabstop=4 " default to two spaces
16+
set softtabstop=4 " default to two spaces
17+
set shiftround " always round indentation to shiftwidth
18+
set mouse= " disable mouse
19+
set expandtab
20+
set backspace=indent,eol,start
21+
22+
source /root/.vimrc.after

0 commit comments

Comments
 (0)