Skip to content

Commit

Permalink
restructure
Browse files Browse the repository at this point in the history
  • Loading branch information
Hackebein committed Aug 8, 2024
1 parent 694118b commit 5f9d7a8
Show file tree
Hide file tree
Showing 211 changed files with 151 additions and 4,710 deletions.
57 changes: 19 additions & 38 deletions .github/workflows/build-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,70 +6,51 @@ on:
- "*.*.*"

jobs:

# Validate Repository Configuration
config:
runs-on: ubuntu-latest
outputs:
config_package: ${{ steps.config_package.outputs.configPackage }}
steps:

# Ensure that required repository variable has been created for the Package
- name: Validate Package Config
id: config_package
run: |
if [ "${{ vars.PACKAGE_NAME }}" != "" ]; then
echo "configPackage=true" >> $GITHUB_OUTPUT;
else
echo "configPackage=false" >> $GITHUB_OUTPUT;
fi
# Build and release the Package
# If the repository is not configured properly, this job will be skipped
build:
needs: config
runs-on: ubuntu-latest
permissions:
contents: write
env:
packagePath: Packages/${{ vars.PACKAGE_NAME }}
if: needs.config.outputs.config_package == 'true'
steps:

# Checkout Local Repository
- name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac

# Get the Package version based on the package.json file
- name: Get Name
id: name
uses: zoexx/github-action-json-file-properties@b9f36ce6ee6fe2680cd3c32b2c62e22eade7e590
with:
file_path: package.json
prop_path: name

- name: Get Version
id: version
uses: zoexx/github-action-json-file-properties@b9f36ce6ee6fe2680cd3c32b2c62e22eade7e590
with:
file_path: "${{ env.packagePath }}/package.json"
prop_path: "version"
file_path: package.json
prop_path: version

# Configure the Environment Variables needed for releasing the Package
- name: Set Environment Variables
run: |
echo "zipFile=${{ vars.PACKAGE_NAME }}-${{ steps.version.outputs.value }}".zip >> $GITHUB_ENV
echo "unityPackage=${{ vars.PACKAGE_NAME }}-${{ steps.version.outputs.value }}.unitypackage" >> $GITHUB_ENV
echo "zipFile=${{ steps.name.outputs.value }}-${{ steps.version.outputs.value }}".zip >> $GITHUB_ENV
echo "unityPackage=${{ steps.name.outputs.value }}-${{ steps.version.outputs.value }}.unitypackage" >> $GITHUB_ENV
echo "version=${{ steps.version.outputs.value }}" >> $GITHUB_ENV
# Zip the Package for release
- name: Create Package Zip
working-directory: "${{ env.packagePath }}"
run: zip -r "${{ github.workspace }}/${{ env.zipFile }}" .
# Build a list of .meta files for future use
# *.unitypackage
- name: Track Package Meta Files
run: find "${{ env.packagePath }}/" -name \*.meta >> metaList
run: find . -name \*.meta > metaList

# Make a UnityPackage version of the Package for release
- name: Create UnityPackage
uses: pCYSl5EDgo/create-unitypackage@b5c57408698b1fab8b3a84d4b67f767b8b7c0be9
with:
package-path: ${{ env.unityPackage }}
include-files: metaList

# *.zip
- name: Create Package Zip
run: |
sed 'p;s/\.meta$//' metaList > fileList
zip -r ${{ env.zipFile }} . -i @fileList
# Publish the Release to GitHub
- name: Make Release
Expand Down
30 changes: 2 additions & 28 deletions .github/workflows/bump-version.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,48 +8,22 @@ on:
required: true

jobs:

# Validate Repository Configuration
config:
runs-on: ubuntu-latest
outputs:
config_package: ${{ steps.config_package.outputs.configPackage }}
steps:

# Ensure that required repository variable has been created for the Package
- name: Validate Package Config
id: config_package
run: |
if [ "${{ vars.PACKAGE_NAME }}" != "" ]; then
echo "configPackage=true" >> $GITHUB_OUTPUT;
else
echo "configPackage=false" >> $GITHUB_OUTPUT;
fi
# Build and release the Package
# If the repository is not configured properly, this job will be skipped
build:
needs: config
runs-on: ubuntu-latest
permissions:
contents: write
#pull-requests: write
env:
packagePath: Packages/${{ vars.PACKAGE_NAME }}
if: needs.config.outputs.config_package == 'true'
steps:

- name: Checkout
uses: actions/checkout@3df4ab11eba7bda6032a0b82a6bb43b11571feac
with:
persist-credentials: false # otherwise, the token used is the GITHUB_TOKEN, instead of your personal access token.
persist-credentials: false
fetch-depth: 0
#token: ${{ secrets.TOKEN }}

- name: Update package.json
uses: jossef/action-set-json-field@890d7642122dbb2833dddd2003659bb71a2b21fe
with:
file: ${{ env.packagePath }}/package.json
file: package.json
field: version
value: ${{ github.event.inputs.version }}

Expand Down
66 changes: 2 additions & 64 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,64 +1,2 @@
# This .gitignore file should be placed at the root of your Unity project directory
#
# Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore
#
/[Ll]ibrary/
/[Tt]emp/
/[Oo]bj/
/[Bb]uild/
/[Bb]uilds/
/[Ll]ogs/
/[Mm]emoryCaptures/

# Asset meta data should only be ignored when the corresponding asset is also ignored
!/[Aa]ssets/**/*.meta

# Uncomment this line if you wish to ignore the asset store tools plugin
# /[Aa]ssets/AssetStoreTools*

# Autogenerated Jetbrains Rider plugin
[Aa]ssets/Plugins/Editor/JetBrains*

# Visual Studio cache directory
.vs/

# Gradle cache directory
.gradle/

# Autogenerated VS/MD/Consulo solution and project files
ExportedObj/
.consulo/
*.csproj
*.unityproj
*.sln
*.suo
*.tmp
*.user
*.userprefs
*.pidb
*.booproj
*.svd
*.pdb
*.mdb
*.opendb
*.VC.db

# Unity3D generated meta files
*.pidb.meta
*.pdb.meta
*.mdb.meta

# Unity3D generated file on crash reports
sysinfo.txt

# Builds
*.apk
*.unitypackage

# Crashlytics generated file
crashlytics-build.properties

.idea/.idea.vpm-package-maker/.idea
Assets/PackageMakerWindowData.asset*
.idea
.vscode
.idea
.vscode
2 changes: 0 additions & 2 deletions Assets/.gitignore

This file was deleted.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion ...dev.hackebein.object-tracking/Assets.meta → Docs.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

127 changes: 127 additions & 0 deletions Docs/setup_script.png.meta

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
6 changes: 0 additions & 6 deletions Packages/.gitignore

This file was deleted.

8 changes: 0 additions & 8 deletions Packages/com.vrchat.core.bootstrap/Editor.meta

This file was deleted.

Loading

0 comments on commit 5f9d7a8

Please sign in to comment.