Command line tool to run any of the SCE projects. Works on Windows, Mac and
Linux. Available with the sce
command.
Before starting, be sure you have Docker installed! This tool runs SCE's projects with Docker.
Clone this repository to your computer with
git clone https://github.com/SCE-Development/SCE-CLI.git
Next, we will add the sce
command to your terminal.
You will need to add the location where the batch file is to your path. To do this:
- Copy the path where
SCE-CLI
is installed. The path should look like
C:\Users\<username>\path\to\SCE-CLI\
- We need to edit (your env vars or something) we can do this with:
- Press
Window + R
to open the Windows Run prompt. - Type in
sysdm.cpl
and clickOK
. - Then go to the
Advanced
tab and clickEnvironment Variables
: - Click on path in
System variables
- Add the location where
SCE-CLI
is installed from earlier into this path (see highlighted)
- After doing so, typing
sce
in the Command Prompt should work, and the help page should show like below:
- cd into the
SCE-CLI
- Add an alias to your terminals config file like:
# for linux
./sce.sh completion >> ~/.bashrc
# for mac
./sce.sh completion >> ~/.zshrc
- After doing the above, making a new terminal and typing
sce
should work.
To use the script, you use the command sce
with a command and repo name
The commands that you can run are: clone, link, run.
Alternatively, just run the command sce
to see the usages in the terminal.
The name of the repositories are (the nicknames are alternate names you can use in the command): core-v4 (nicknames: core-v4, corev4, cv4, c4, c) quasar (nicknames: quasar, q, idsmile) sce-discord-bot (nicknames: sce-discord-bot, discord-bot, discord, bot, d)
To clone an SCE project from GitHub, simply enter
sce clone <project> [--ssh]
The reposity will be cloned from wherever the command was ran.
Project names can be quasar
, core-v4
, discord
etc. See the above repo
names section for all options.
The --ssh
parameter can be optionally added after the project name.
Supplying this will clone the repo with the GitHub SSH URL over the
HTTPS one.
To link a sce repo to your directory where you are running the command, simply enter
sce link <project>
Project names can be quasar
, core-v4
, discord
etc. See the above repo
names section for all options.
To run an SCE project, simply enter
sce run <project>
where project can be quasar
, core-v4
, discord
etc. See the above repo
names section for all options.
This will create a test account when running the SCE website locally. Before running, make sure you have MongoDB running with:
sce run db
Then, run the below command:
sce create
After running the SCE website locally, ensure you can log in with the email
test@one.sce
and password sce