summaryrefslogtreecommitdiff
path: root/docs/technical
diff options
context:
space:
mode:
Diffstat (limited to 'docs/technical')
-rw-r--r--docs/technical/smapi.md33
-rw-r--r--docs/technical/web.md30
2 files changed, 37 insertions, 26 deletions
diff --git a/docs/technical/smapi.md b/docs/technical/smapi.md
index c9d5c07e..ca8a9c70 100644
--- a/docs/technical/smapi.md
+++ b/docs/technical/smapi.md
@@ -15,6 +15,7 @@ This document is about SMAPI itself; see also [mod build package](mod-package.md
* [Compiling from source](#compiling-from-source)
* [Debugging a local build](#debugging-a-local-build)
* [Preparing a release](#preparing-a-release)
+ * [Using a custom Harmony build](#using-a-custom-harmony-build)
* [Release notes](#release-notes)
## Customisation
@@ -60,21 +61,18 @@ flag | purpose
## For SMAPI developers
### Compiling from source
-Using an official SMAPI release is recommended for most users.
+Using an official SMAPI release is recommended for most users, but you can compile from source
+directly if needed. There are no special steps (just open the project and compile), but SMAPI often
+uses the latest C# syntax. You may need the latest version of your IDE to compile it.
-SMAPI often uses the latest C# syntax. You may need the latest version of
-[Visual Studio](https://www.visualstudio.com/vs/community/) on Windows,
-[MonoDevelop](https://www.monodevelop.com/) on Linux,
-[Visual Studio for Mac](https://www.visualstudio.com/vs/visual-studio-mac/), or an equivalent IDE
-to compile it. It uses build configuration derived from the
-[crossplatform mod config](https://smapi.io/package/readme) to detect your current OS automatically
-and load the correct references. Compile output will be placed in a `bin` folder at the root of the
-git repository.
+SMAPI uses build configuration derived from the [crossplatform mod config](https://smapi.io/package/readme)
+to detect your current OS automatically and load the correct references. Compile output will be
+placed in a `bin` folder at the root of the Git repository.
### Debugging a local build
Rebuilding the solution in debug mode will copy the SMAPI files into your game folder. Starting
the `SMAPI` project with debugging from Visual Studio (on Mac or Windows) will launch SMAPI with
-the debugger attached, so you can intercept errors and step through the code being executed. This
+the debugger attached, so you can intercept errors and step through the code being executed. That
doesn't work in MonoDevelop on Linux, unfortunately.
### Preparing a release
@@ -87,9 +85,9 @@ on the wiki for the first-time setup.
build type | format | example
:--------- | :----------------------- | :------
- dev build | `<version>-alpha.<date>` | `3.0-alpha.20171230`
- prerelease | `<version>-beta.<count>` | `3.0-beta.2`
- release | `<version>` | `3.0`
+ dev build | `<version>-alpha.<date>` | `3.0.0-alpha.20171230`
+ prerelease | `<version>-beta.<count>` | `3.0.0-beta.2`
+ release | `<version>` | `3.0.0`
2. In Windows:
1. Rebuild the solution in Release mode.
@@ -103,5 +101,14 @@ on the wiki for the first-time setup.
3. Rename the folders to `SMAPI <version> installer` and `SMAPI <version> installer for developers`.
4. Zip the two folders.
+### Using a custom Harmony build
+The official SMAPI releases include [a custom build of Harmony](https://github.com/Pathoschild/Harmony),
+but compiling from source will use the official build. To use a custom build, put `0Harmony.dll` in
+the `build` folder and it'll be referenced automatically.
+
+Note that Harmony merges its dependencies into `0Harmony.dll` when compiled in release mode. To use
+a debug build of Harmony, you'll need to manually copy those dependencies into your game's
+`smapi-internal` folder.
+
## Release notes
See [release notes](../release-notes.md).
diff --git a/docs/technical/web.md b/docs/technical/web.md
index 67e86c8b..d21b87ac 100644
--- a/docs/technical/web.md
+++ b/docs/technical/web.md
@@ -340,9 +340,19 @@ short url | → | target page
A local environment lets you run a complete copy of the web project (including cache database) on
your machine, with no external dependencies aside from the actual mod sites.
-1. Enter the Nexus credentials in `appsettings.Development.json` . You can leave the other
- credentials empty to default to fetching data anonymously, and storing data in-memory and
- on disk.
+1. Edit `appsettings.Development.json` and set these options:
+
+ property name | description
+ ------------- | -----------
+ `NexusApiKey` | [Your Nexus API key](https://www.nexusmods.com/users/myaccount?tab=api#personal_key).
+
+ Optional settings:
+
+ property name | description
+ --------------------------- | -----------
+ `AzureBlobConnectionString` | The connection string for the Azure Blob storage account. Defaults to using the system's temporary file folder if not specified.
+ `GitHubUsername`<br />`GitHubPassword` | The GitHub credentials with which to query GitHub release info. Defaults to anonymous requests if not specified.
+
2. Launch `SMAPI.Web` from Visual Studio to run a local version of the site.
### Production environment
@@ -355,19 +365,15 @@ accordingly.
Initial setup:
-1. Launch an empty MongoDB server (e.g. using [MongoDB Atlas](https://www.mongodb.com/cloud/atlas))
- for mod data.
-2. Create an Azure Blob storage account for uploaded files.
-3. Create an Azure App Services environment running the latest .NET Core on Linux or Windows.
-4. Add these application settings in the new App Services environment:
+1. Create an Azure Blob storage account for uploaded files.
+2. Create an Azure App Services environment running the latest .NET Core on Linux or Windows.
+3. Add these application settings in the new App Services environment:
property name | description
------------------------------- | -----------------
`ApiClients.AzureBlobConnectionString` | The connection string for the Azure Blob storage account created in step 2.
`ApiClients.GitHubUsername`<br />`ApiClients.GitHubPassword` | The login credentials for the GitHub account with which to fetch release info. If these are omitted, GitHub will impose much stricter rate limits.
`ApiClients:NexusApiKey` | The [Nexus API authentication key](https://github.com/Pathoschild/FluentNexus#init-a-client).
- `MongoDB:ConnectionString` | The connection string for the MongoDB instance.
- `MongoDB:Database` | The MongoDB database name (e.g. `smapi` in production or `smapi-edge` in testing environments).
Optional settings:
@@ -378,6 +384,4 @@ Initial setup:
`Site:BetaBlurb` | If `Site:BetaEnabled` is true and there's a beta version of SMAPI in its GitHub releases, this is shown on the beta download button as explanatory subtext.
`Site:SupporterList` | A list of Patreon supports to credit on the download page.
-To deploy updates:
-1. [Deploy the web project from Visual Studio](https://docs.microsoft.com/en-us/visualstudio/deployment/quickstart-deploy-to-azure).
-2. If the MongoDB schema changed, delete the MongoDB database. (It'll be recreated automatically.)
+To deploy updates, just [redeploy the web project from Visual Studio](https://docs.microsoft.com/en-us/visualstudio/deployment/quickstart-deploy-to-azure).