-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathinstall.sh
executable file
·32 lines (27 loc) · 1.43 KB
/
install.sh
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
#!/usr/bin/env bash
# If you remove the .example extension from the file, once your workspace is created and the contents of this
# repo are copied into it, this script will execute. This will happen in place of the default behavior of the workspace system,
# which is to symlink the dotfiles copied from this repo to the home directory in the workspace.
#
# Why would one use this file in stead of relying upon the default behavior?
#
# Using this file gives you a bit more control over what happens.
# If you want to do something complex in your workspace setup, you can do that here.
# Also, you can use this file to automatically install a certain tool in your workspace, such as vim.
#
# Just in case you still want the default behavior of symlinking the dotfiles to the root,
# we've included a block of code below for your convenience that does just that.
set -euo pipefail
DOTFILES_PATH="$HOME/dotfiles"
# Symlink dotfiles to the root within your workspace
find $DOTFILES_PATH -type f -path "$DOTFILES_PATH/.*" |
while read df; do
link=${df/$DOTFILES_PATH/$HOME}
mkdir -p "$(dirname "$link")"
ln -sf "$df" "$link"
done
sudo apt-get update
sudo apt-get install -y rsync silversearcher-ag
curl -L https://binaries.ddbuild.io/service-discovery-platform/fabric_1.117.1_linux_amd64.tar.gz -o fabric.tgz && tar -xvf fabric.tgz && mv ./fabric $HOME/.local/bin
cp $DOTFILES_PATH/git-pre-commit ~/dd/dd-source/.git/hooks/;
touch $HOME/.dotfiles_installed