diff --git a/.gitignore b/.gitignore index 33a2ede6..4b0c3cd0 100644 --- a/.gitignore +++ b/.gitignore @@ -168,7 +168,11 @@ log.xml profiling/ *.orig .vs/ -#.vscode/ +.vscode/* +!.vscode/settings.json +!.vscode/tasks.json +!.vscode/launch.json +!.vscode/extensions.json .build/ .testPublish/ diff --git a/.vscode/launch.json b/.vscode/launch.json new file mode 100644 index 00000000..4e4d2fea --- /dev/null +++ b/.vscode/launch.json @@ -0,0 +1,30 @@ +{ + // Use IntelliSense to learn about possible attributes. + // Hover to view descriptions of existing attributes. + // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387 + "version": "0.2.0", + "configurations": [ + { + "name": "Lombiq.TrainingDemo.Web .NET Core Launch (web)", + "type": "coreclr", + "request": "launch", + "preLaunchTask": "build", + "program": "${workspaceFolder}/Lombiq.TrainingDemo.Web/bin/Debug/net8.0/Lombiq.TrainingDemo.Web.dll", + "args": [], + "cwd": "${workspaceFolder}/Lombiq.TrainingDemo.Web", + "stopAtEntry": false, + "serverReadyAction": { + "action": "openExternally", + "pattern": "\\bNow listening on:\\s+(https?://\\S+)" + }, + "env": { + "ASPNETCORE_ENVIRONMENT": "Development" + }, + "sourceFileMap": { + "/Views": "${workspaceFolder}/Views" + }, + "launchSettingsFilePath": "${workspaceFolder}/Lombiq.TrainingDemo.Web/Properties/launchSettings.json", + "launchSettingsProfile": "Lombiq.TrainingDemo.Web" + } + ] +} \ No newline at end of file diff --git a/.vscode/tasks.json b/.vscode/tasks.json new file mode 100644 index 00000000..31c32bd3 --- /dev/null +++ b/.vscode/tasks.json @@ -0,0 +1,24 @@ +{ + // See https://go.microsoft.com/fwlink/?LinkId=733558 + // for the documentation about the tasks.json format + "version": "2.0.0", + "tasks": [ + { + "label": "build", + "command": "dotnet", + "type": "shell", + "args": [ + "build", + // Ask dotnet build to generate full paths for file names. + "/property:GenerateFullPaths=true", + // Do not generate summary otherwise it leads to duplicate errors in Problems panel + "/consoleloggerparameters:NoSummary" + ], + "group": "build", + "presentation": { + "reveal": "silent" + }, + "problemMatcher": "$msCompile" + } + ] +} \ No newline at end of file diff --git a/Readme.md b/Readme.md index 8ccdd943..bee4d693 100644 --- a/Readme.md +++ b/Readme.md @@ -22,10 +22,12 @@ Before you dive deep into this module it'd be best if you make sure that you hav The module comes with its own standalone solution and web app. So, to run it, simply do the following: -1. Clone this repository to the latest `dev` branch or download the source. -2. Open the solution in your favorite IDE, like Visual Studio. -3. Make sure the `Lombiq.TrainingDemo.Web` project is the startup project (it should be). -4. Start the app. In Visual Studio, you can do this with Ctrl + F5. From the .NET CLI, run `dotnet run` in the _Lombiq.TrainingDemo.Web_ folder and then open in a browser. +1. Clone the latest `dev` branch of this repository or [download the source](https://github.com/Lombiq/Orchard-Training-Demo-Module/archive/refs/heads/dev.zip). +2. Open the solution in your favorite IDE, like [Visual Studio](https://visualstudio.microsoft.com/), [Visual Studio Code](https://code.visualstudio.com/) or [Rider](https://www.jetbrains.com/rider/). +3. Make sure the `Lombiq.TrainingDemo.Web` project is the startup project (it should be; not needed for VS Code). +4. Start the app. + - In Visual Studio and VS Code, you can do this with Ctrl + F5. + - From the .NET CLI, run `dotnet run` in the _Lombiq.TrainingDemo.Web_ folder and then open in a browser. 5. The site will be automatically set up with the "Training Demo" recipe (since we use Orchard Core's [Auto Setup feature](https://docs.orchardcore.net/en/latest/docs/reference/modules/AutoSetup/)). You'll be able to log in with the username "admin" and password "Password1!". Once the app is running: