Giter Club home page Giter Club logo

resonitesamplemod's Introduction

ResoniteSampleMod

Build & Test (MonkeyLoader) Build & Test (ResoniteModLoader)

A Mod for Resonite that just adds a "Hello World!" log entry whenever you click a button.

About this repository

This repository is a template everyone can copy from. It includes automatic github workflows to test your code (Continuous Integration including linting and style checking) and a manually triggered release workflow to publish a new version. Mods created using this template support two different mod loaders: ResoniteModLoader and MonkeyLoader

Using this Template

  1. Use this repository as a template (green button Use this template/Create a new repository on the top right)
  2. Inside the new repository go to the tab Actions and run the workflow Init Template (You can specify user/mod names that differ from the repository.)
  3. After the action is finished, follow the instructions in the newly created Issue Setup repository to support full CI/CD (most likely #1 when reading this in your repository)
  4. On your local machine make sure that the environment variables ResonitePath (required) and ResoniteCache (recommended) are set and that you have at least one mod loader installed.
  5. ???
  6. Happy coding!

Additional Notes:

  • This template uses a shared project to reduce redundancies between the different mod loader variants. (Using solution internal dependencies would cause multiple dll files to be output. To reduce the inconvenience for ResoniteModLoader users I chose this hacky workaround.) Only open one of those projects at a time to avoid bugs with Visual Studio! If you open multiple variants at a time you may encounter warning messages and cannot save changes to the csproj files! Restarting Visual Studio makes sure that the error messages go away.
  • You can freely add dependencies to your project. Shared dependencies should be added to the project SampleMod.csproj (without suffix!) to keep dependencies of the variants in sync.
  • There are unit tests using the mod loader independent project.
  • You can start Resonite directly from Visual Studio. The dll files/NuGet packages will be directly copied into the Resonite install. If you add additional files you have to adjust the scripts in the files SampleModMonkey.csproj and SampleModRML.csproj. The file manifest-template.json and the step Build of workflow Build & Test (ResoniteModLoader) need to be adjusted for proper release automation, too. (TODO: hints for NuGet-based MonkeyLoader mods)

Publishing a new Mod Version

  1. Increment the <Version> number within the files SampleMod.csproj and Mod.RML/SampleModRML.cs
  2. Execute the github workflow Create Release

Installation (ResoniteModLoader)

  1. Install ResoniteModLoader.
  2. Download release zip file and extract contents into Resonite directory. (e.g. rml_mods should be merged with rml_mods.)
  3. Start Resonite. (with -LoadAssembly Libraries/ResoniteModLoader.dll launch option)

Installation (MonkeyLoader)

(Work in Progress)

  1. Install MonkeyLoader.
  2. Add package source "https://nuget.pkg.github.com/mpmxyz/index.json"
  3. Add package "mpmxyz.SampleMod.MonkeyLoader"
  4. Start Resonite.

resonitesamplemod's People

Contributors

mpmxyz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

resonitesamplemod's Issues

add github release based trigger

requires #35
Possible chain of actions would be:

  1. optional: manual OR tag trigger
    1a. create github release draft
    OR
    1b. update release draft and trigger next step if manual has "override" and release draft already exists
  2. on created release draft or trigger from previous step (verify version format first!)
    2a. RML compile/test
    2b. MonkeyLoader compile/test
  3. after compilation/tests are finished
    3a. RML
    3a.1. add artifacts to release
    3a.2. amend RML manifest
    3b. MonkeyLoader
    3b.1. push nuget package
  4. make release public

Problem with that approach: github release will be created before code is compiled/tested.

Allow updating/overriding a release

[ ] add option to override/amend existing release
[ ] don't override title/description of existing github release
[ ] make sure not to tell ncipollo/release-action to create new tag/release when merging
[ ] handle existing branch in RML manifest repository
[ ] handle existing nuget package

enables #14 and github release based triggers in parallel to current approach

Add RML workflow

  • goal: shared code between RML and MonkeyLoader
  • release should include a zip file mirroring install positions

split project into different flavors

  • Common
    • Test
    • ResoniteModLoader
    • MonkeyLoader

Problem: creates multiple dll files for RML releases
Solution: ILMerge or something up-to-date OR <import> common part into mod-specific parts

Self-adjusting template

  • create a workflow that reacts to being instantiated in a non-fork
  • creates a pull request with adjusted names
  • create issues for TODOs (Secrets, replacing/removing workflow files etc.)

create tag trigger for release

goal: release from within IDE by attaching a tag vX.Y.Z (latest commit message as description?)
potential issue: Creating a release creates a tag. Does this trigger another release?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.