mirror of
https://github.com/Llewellynvdm/exa.git
synced 2025-02-04 19:48:25 +00:00
Convert the aliases to actual files
This commit is contained in:
parent
b5bd76b548
commit
32ab6a5823
13
Vagrantfile
vendored
13
Vagrantfile
vendored
@ -7,6 +7,8 @@ Vagrant.configure(2) do |config|
|
|||||||
v.cpus = 1
|
v.cpus = 1
|
||||||
end
|
end
|
||||||
|
|
||||||
|
developer = 'ubuntu'
|
||||||
|
|
||||||
|
|
||||||
# We use Ubuntu instead of Debian because the image comes with two-way
|
# We use Ubuntu instead of Debian because the image comes with two-way
|
||||||
# shared folder support by default.
|
# shared folder support by default.
|
||||||
@ -43,15 +45,16 @@ Vagrant.configure(2) do |config|
|
|||||||
grep -q -F "$2" $1 || echo "$2" >> $1
|
grep -q -F "$2" $1 || echo "$2" >> $1
|
||||||
}
|
}
|
||||||
|
|
||||||
put_line ~/.bashrc 'export CARGO_TARGET_DIR=/home/ubuntu/target'
|
echo -e "#!/bin/sh\necho \"Use 'dexa' for debug exa, or 'rexa' for release exa\"" > /usr/bin/exa
|
||||||
put_line ~/.bashrc 'alias dexa=~/target/debug/exa'
|
echo -e "#!/bin/sh\n/home/#{developer}/target/debug/exa" > /usr/bin/dexa
|
||||||
put_line ~/.bashrc 'alias rexa=~/target/release/exa'
|
echo -e "#!/bin/sh\n/home/#{developer}/target/release/exa" > /usr/bin/rexa
|
||||||
|
chmod +x /usr/bin/{exa,dexa,rexa}
|
||||||
EOF
|
EOF
|
||||||
|
|
||||||
|
|
||||||
# We create two users that own the test files.
|
# We create two users that own the test files.
|
||||||
# The first one just owns the ordinary ones, because we don’t want to
|
# The first one just owns the ordinary ones, because we don’t want the
|
||||||
# depend on “vagrant” or “ubuntu” existing.
|
# test outputs to depend on “vagrant” or “ubuntu” existing.
|
||||||
user = "cassowary"
|
user = "cassowary"
|
||||||
config.vm.provision :shell, privileged: true, inline:
|
config.vm.provision :shell, privileged: true, inline:
|
||||||
%[id -u #{user} &>/dev/null || useradd #{user}]
|
%[id -u #{user} &>/dev/null || useradd #{user}]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user