-
Install Postgres, the recommended way is to use the EnterpriseDB installer. You need version 12 or newer.
-
Start "pgAdmin", a web interface should open.
-
Create a new user, this can be done by right-clicking on
Servers > PostgreSQL > Login/Group Roles
and selectingCreate > Login/Group Role...
. You can choose any name, the instructions assume that you choose "codidact". Make sure to select "Can login?" in the "Privileges" tab. It is necessary to add a password to this account, do this in the "Definition" tab, the instructions assume that you choose "codidact". (Providing a password isn't necessary on Linux, but on Windows it is. If you find a way to bypass this requirement, please create an issue.) -
Create a new database, this can be done by right-clicking on
Servers > PostgreSQL > Databases
and selectingCreate > Database...
. You can choose any name, the instructions assume that you choose "codidact". Make sure that the owner is set to the user that you created before. -
Prepare a connection string for later use, the format is
Host=localhost;Database=X;Username=X;Password=X
. If you honored the suggestions, you would have the connection stringHost=localhost;Database=codidact;Username=codidact;Password=codidact
.
- Run the following command inside of 'src/WebUI' to install the connection string
dotnet user-secrets set "ConnectionStrings:DefaultConnection" "YOUR_CONNECTION_STRING"
-
Install Visual Studio if you haven't already, the "Community" edition is sufficent.
-
Ensure that the "ASP.NET and Web Development" workload is installed, this can be done during installation or later by starting the "Visual Studio Installer" application and selecting "Modify".
-
Next, clone the repository. This can be done using Visual Studio by selecting "Clone or check out code" in the launcher. Alternativly, you can clone the repository manually with Git for Windows. The URL is
https://github.com/codidact/core
. -
Create a new branch, note that there is a naming convention for branches. This can be done at the bottom right of the screen, by clicking on the current branch and selecting
New Branch...
. -
For some reason Visual Studio opens the repository as folder and not as a solution. It's not possible to launch the application in this state. There should be a popup message in the solution explorer to "Switch Views", do that.
-
You can launch the application by clicking
Debug > Start Debugging
. -
You can run the integration tests by clicking
Test > Run all Tests
.
-
Install the .NET Core SDK this is not necessary if you have Visual Studio with the required workload installed. You need version 3.1 or newer.
-
Install Git for Windows and clone the repository somewhere, the URL is
https://github.com/codidact/core
. -
Create a new branch, notice that there is a naming convention for branches.
-
Setup the
appsettings.Development.json
file insrc/WebUI
, refer to the instructions for Visual Studio. -
You can launch the appliation by executing
dotnet run
in thesrc/WebUI
directory. -
You can run the integration tests using
dotnet test
in the root directory.
You'll also need to set up the auth provider. See these instructions for more information.