-
Notifications
You must be signed in to change notification settings - Fork 49
/
.gitpod.yml
81 lines (62 loc) · 2.47 KB
/
.gitpod.yml
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
# Generated by cynkrathis::use_gitpod(), do not edit by hand
#
# Call:
# quote(cynkrathis::use_gitpod())
tasks:
- name: dependencies
init: |
# Set up rig
curl -Ls https://github.com/r-lib/rig/releases/download/latest/rig-linux-latest.tar.gz | sudo tar xz -C /usr/local
# Set up R
rig install
rig system add-pak
rig system make-links
rig system setup-user-lib
# Deps
sudo apt install -y ccache cmake
# Scriptlets, with custom Git config
mv ~/.gitconfig ~/.gitconfig.gitpod
curl -s https://raw.githubusercontent.com/krlmlr/scriptlets/master/bootstrap | sh
## .editorconfig
ln -s ~/.editorconfig ..
## Set up ccache
ln -s /usr/lib/ccache/* ~/bin/
## Work around glitch with non-systemd systems
ln -s $(which true) ~/bin/timedatectl
## Define PATH
# FIXME: Why is this necessary? This doesn't work in Radian.
echo 'export PATH='${HOME}'/bin:${PATH}' >> ~/.bashrc
# Set up Makevars
mkdir -p ~/.R
echo -e "MAKEFLAGS = -j8\nCXXFLAGS = -O0 -g" > ~/.R/Makevars
# Install R packages
echo 'options(repos = "https://packagemanager.rstudio.com/all/__linux__/'$(cat /etc/lsb-release | sed -n '/DISTRIB_CODENAME=/ {s///;p}')'/latest")' >> ~/.Rprofile
## Install devtools and R dependencies
R -q -e 'pak::pak(c("devtools", "languageserver", "styler")); pak::pak("deps::.", dependencies = TRUE)'
# Install radian
sudo pip install radian
## Install Postgres server
sudo apt-get install -y postgresql
## Start Postgres server
sudo service postgresql start
## Configure test database
sudo sudo -u postgres createuser -s $USER
createdb ${USER}
## Install MariaDB server
sudo apt-get install -y mariadb-server mariadb-client
## Start MariaDB server
sudo service mysql start
## Configure test database
sudo mysql -e "CREATE DATABASE IF NOT EXISTS test; ALTER DATABASE test CHARACTER SET 'utf8'; FLUSH PRIVILEGES;"
vscode:
extensions:
- ms-vscode.cpptools
# needs reload of VS Code to be operational
- go2sh.cmake-integration-vscode
# buggy -- doesn't reliably interpret include files?
# observed behavior: repeated saving of src/CMakeLists.txt
# changes detaction of include files -- sometimes it works, sometimes it doesn't,
# with no detectable pattern
# - ms-vscode.cmake-tools
- EditorConfig.EditorConfig
- REditorSupport.r