Initial commit
This commit is contained in:
commit
ac283355f3
4 changed files with 61 additions and 0 deletions
1
.gitignore
vendored
Normal file
1
.gitignore
vendored
Normal file
|
@ -0,0 +1 @@
|
||||||
|
tools/
|
9
.gitmodules
vendored
Normal file
9
.gitmodules
vendored
Normal file
|
@ -0,0 +1,9 @@
|
||||||
|
[submodule "dformat"]
|
||||||
|
path = dformat
|
||||||
|
url = https://github.com/dlang-community/dfmt.git
|
||||||
|
[submodule "dcd"]
|
||||||
|
path = dcd
|
||||||
|
url = https://github.com/dlang-community/DCD.git
|
||||||
|
[submodule "dscanner"]
|
||||||
|
path = dscanner
|
||||||
|
url = https://github.com/dlang-community/D-Scanner.git
|
7
README.md
Normal file
7
README.md
Normal file
|
@ -0,0 +1,7 @@
|
||||||
|
# d-setup
|
||||||
|
|
||||||
|
Setup D language development environment for linux in a janky fashion
|
||||||
|
|
||||||
|
Will setup DMD and LDC compilers (Can be found in ~/dlang)
|
||||||
|
|
||||||
|
Will build DCD, DFormat, DScanner tools for use in jetbrains IDE (can be found in ./tools)
|
44
setup.sh
Executable file
44
setup.sh
Executable file
|
@ -0,0 +1,44 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
ACCENT='\033[1;32m'
|
||||||
|
NC='\033[0m' # No Color
|
||||||
|
|
||||||
|
# Update submodules
|
||||||
|
echo -e "${ACCENT}Updating submodules${NC}\n"
|
||||||
|
git pull --recurse-submodules
|
||||||
|
git submodule update --init --recursive
|
||||||
|
|
||||||
|
# Setup compilers and activate DMD
|
||||||
|
echo -e "\n${ACCENT}Setting up compilers${NC}\n"
|
||||||
|
|
||||||
|
curl -fsS https://dlang.org/install.sh | bash -s dmd
|
||||||
|
curl -fsS https://dlang.org/install.sh | bash -s ldc
|
||||||
|
|
||||||
|
DMDDIR=$(ls -d ~/dlang/dmd-*/ | head -1)
|
||||||
|
|
||||||
|
echo -e "\n${ACCENT}Activating DMD with ${DMDDIR}${NC}\n"
|
||||||
|
source $DMDDIR/activate
|
||||||
|
dmd --version
|
||||||
|
|
||||||
|
# Build tools
|
||||||
|
|
||||||
|
mkdir -p ./tools
|
||||||
|
|
||||||
|
echo -e "\n${ACCENT}Building Tools${NC}"
|
||||||
|
echo -e "\n${ACCENT} - DFormat${NC}\n"
|
||||||
|
cd dformat
|
||||||
|
make
|
||||||
|
mv -f ./bin/dfmt ../tools/dfmt
|
||||||
|
|
||||||
|
echo -e "\n${ACCENT} - D-Scanner${NC}\n"
|
||||||
|
cd ../dscanner
|
||||||
|
make
|
||||||
|
mv -f ./bin/dscanner ../tools/dscanner
|
||||||
|
|
||||||
|
echo -e "\n${ACCENT} - DCD${NC}\n"
|
||||||
|
cd ../dcd
|
||||||
|
make
|
||||||
|
mv -f ./bin/dcd-client ../tools/dcd-client
|
||||||
|
mv -f ./bin/dcd-server ../tools/dcd-server
|
||||||
|
|
||||||
|
echo -e "\n${ACCENT}Complete"
|
Loading…
Reference in a new issue