verifyConditions: - "@semantic-release/github" plugins: # Determines the type of release to create, if any. # See https://github.com/angular/angular.js/blob/master/DEVELOPERS.md#type # More types can be added here and in release-notes-generator below. - - '@semantic-release/commit-analyzer' - preset: "angular" releaseRules: - type: "breaking" release: "major" - type: "release" release: "major" - type: "feature" release: "minor" # Extends the behavior of semantic-release to generate release notes. # 'fix' and 'feat' are built in and don't need to be defined here. # More types can be added to correspond with commit-analyzer above. - - '@semantic-release/release-notes-generator' - preset: "conventionalcommits" presetConfig: types: - type: "breaking" section: "Breaking Changes" hidden: false - type: "release" section: "Release" hidden: false - type: "feature" section: "Features" hidden: false # Write the new version in version.txt - - '@semantic-release/exec' - prepareCmd: "echo ${nextRelease.version} > Assets/Mirror/version.txt" # Remove Test folder so it's excluded from Unity package # -f: force, -r: recursive, -q: quiet - - '@semantic-release/exec' - prepareCmd: "rm -f -r -q Assets/Mirror/Tests && rm -f -q Assets/Mirror/Tests.meta" # Create Unity package with Mirror, ScriptTemplates, and LICENSE - - '@semantic-release/exec' - prepareCmd: "unity-packer pack Mirror.unitypackage Assets/Mirror Assets/Mirror Assets/ScriptTemplates Assets/ScriptTemplates LICENSE Assets/Mirror/LICENSE" # Create a new release on GitHub - - '@semantic-release/github' - assets: - path: "Mirror.unitypackage" label: "Mirror Unity Package" name: "Mirror-${nextRelease.version}.unitypackage"