Skip to content

Commit

Permalink
Prepared for release
Browse files Browse the repository at this point in the history
  • Loading branch information
Hertzole committed Jun 12, 2022
1 parent 5b36d73 commit 6122675
Show file tree
Hide file tree
Showing 10 changed files with 77 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/dev-package.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Devlopment Package
name: Development Package

on:
push:
Expand Down
30 changes: 30 additions & 0 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Release Package

on:
release:
types:
- published

jobs:
package:
name: Deploy release package
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Create release package branch
run: |
git branch -d package &> /dev/null || echo package branch not found
git subtree split -P "$PKG_ROOT" -b package
mv "Assets/Samples" /tmp/example
git checkout package
mkdir "Samples~"
mv /tmp/example/* "Samples~/"
git add "Samples~"
git config --global user.name 'github-bot'
git config --global user.email '[email protected]'
git commit -am "Packaged project"
git push -f -u origin package
env:
PKG_ROOT: "Packages/se.hertzole.settings-manager"
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ MonoBehaviour:
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 1733b69937f84c0990b3a245c3a43003, type: 3}
m_Name: New Fullscreen Mode Setting
m_Name: Fullscreen
m_EditorClassIdentifier:
displayName: Fullscreen Mode
displayNameLocalized:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ MonoBehaviour:
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: ea58189d66ecb5a4f9ef2a773ac8bfe0, type: 3}
m_Name: New Language Setting
m_Name: Language
m_EditorClassIdentifier:
displayName: Language
displayNameLocalized:
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ MonoBehaviour:
m_Enabled: 1
m_EditorHideFlags: 0
m_Script: {fileID: 11500000, guid: 909ba99dab6f4b8dbde28f05338d1ee2, type: 3}
m_Name: New Resolution Setting
m_Name: Resolution
m_EditorClassIdentifier:
displayName: Resolution
displayNameLocalized:
Expand Down
File renamed without changes.
4 changes: 2 additions & 2 deletions Assets/Settings Manager.asset
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ MonoBehaviour:
m_Name: Settings Manager
m_EditorClassIdentifier:
autoSaveSettings: 1
loadSettingsOnBoot: 0
loadSettingsOnBoot: 1
saveLocation: 0
savePath: settings
fileName: settings.json
Expand Down Expand Up @@ -58,4 +58,4 @@ MonoBehaviour:
- rid: 8729629915173617764
type: {class: JsonSettingSerializer, ns: Hertzole.SettingsManager, asm: Hertzole.SettingsManager}
data:
prettyPrint: 0
prettyPrint: 1
42 changes: 41 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,50 @@
# Unity Runtime Settings
### Experimental drop-in solution for runtime settings

⚠ This is very experimental as of right now! ⚠

[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=unity-runtime-settings&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=unity-runtime-settings)
[![Coverage](https://sonarcloud.io/api/project_badges/measure?project=unity-runtime-settings&metric=coverage)](https://sonarcloud.io/summary/new_code?id=unity-runtime-settings)
[![Reliability Rating](https://sonarcloud.io/api/project_badges/measure?project=unity-runtime-settings&metric=reliability_rating)](https://sonarcloud.io/summary/new_code?id=unity-runtime-settings)
[![Bugs](https://sonarcloud.io/api/project_badges/measure?project=unity-runtime-settings&metric=bugs)](https://sonarcloud.io/summary/new_code?id=unity-runtime-settings)
[![Technical Debt](https://sonarcloud.io/api/project_badges/measure?project=unity-runtime-settings&metric=sqale_index)](https://sonarcloud.io/summary/new_code?id=unity-runtime-settings)

⚠ This is very experimental as of right now! ⚠
## ❓ What is this?

Unity runtime settings is supposed to be a drop-in solution for managing runtime settings for your game. Settings like
resolution, audio volumes, graphics, etc.

![Settings Manager in project settings](https://i.imgur.com/rvus6eV.png)

![Example setting](https://i.imgur.com/7znry27.png)

## 🔨 Quick Start

1. Install the package either using a git link or OpenUPM. See installation section for instructions.
2. Open up your project settings inside Unity and create a new settings manager.
3. Create a setting in your project by right clicking - Create - Hertzole - Settings - the setting of your choice
4. Create a category in your settings manager and assign the settings.
5. Build your UI. I'd recommend importing the uGUI sample to see how you can create a simple UI for your settings.

## 📦 Installation

### OpenUPM (Recommended)
1. Add the OpenUPM reigstry.
Click in the menu bar Edit → Project Settings... → Package Manager
Add a new scoped registry with the following parameters:
Name: `OpenUPM`
URL: `https://package.openupm.com`
Scopes:
- `com.openupm`
- `se.hertzole.unity-runtime-settings`
2. Click apply and close the project settings.
3. Open up the package manager.
Click in the menu bar Window → Package Manager
4. Select `Packages: My Registries` in the menu bar of the package manager window.
5. You should see Unity Runtime Settings under the `Hertzole` section. Click on it and then press Install in the bottom right corner.

### Unity package manager through git
1. Open up the Unity package manager
2. Click on the plus icon in the top left and "Add package from git url"
3. Paste in `https://github.com/Hertzole/unity-runtime-settings.git#package`
You can also paste in `https://github.com/Hertzole/unity-runtime-settings.git#dev-package` if you want the latest (but unstable!) changes.

0 comments on commit 6122675

Please sign in to comment.