-
Notifications
You must be signed in to change notification settings - Fork 71
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
AIRO-1696
- Loading branch information
Showing
23 changed files
with
484 additions
and
114 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
name: jira-link | ||
|
||
on: | ||
pull_request: | ||
types: [opened, edited, reopened, synchronize] | ||
|
||
jobs: | ||
jira-link: | ||
runs-on: ubuntu-20.04 | ||
steps: | ||
- name: check pull request title and source branch name | ||
run: | | ||
echo "Checking pull request with title ${{ github.event.pull_request.title }} from source branch ${{ github.event.pull_request.head.ref }}" | ||
if ! [[ "${{ github.event.pull_request.title }}" =~ ^AIRO-[0-9]+[[:space:]].*$ ]] && ! [[ "${{ github.event.pull_request.head.ref }}" =~ ^AIRO-[0-9]+.*$ ]] | ||
then | ||
echo -e "Please make sure one of the following is true:\n \ | ||
1. the pull request title starts with 'AIRO-xxxx ', e.g. 'AIRO-1024 My Pull Request'\n \ | ||
2. the source branch starts with 'AIRO-xxx', e.g. 'AIRO-1024-my-branch'" | ||
exit 1 | ||
else | ||
echo "Completed checking" | ||
fi |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
name: 'Stale issue handler' | ||
on: | ||
workflow_dispatch: | ||
schedule: | ||
- cron: '0 17 * * *' # 17:00 UTC; 10:00 PDT | ||
|
||
permissions: | ||
issues: write | ||
|
||
jobs: | ||
stale: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
id: stale | ||
with: | ||
stale-issue-label: 'stale' | ||
stale-issue-message: 'This issue has been marked stale because it has been open for 14 days with no activity. Please remove the stale label or comment on this issue, or the issue will be automatically closed in the next 14 days.' | ||
days-before-stale: 14 | ||
days-before-pr-stale: -1 | ||
days-before-close: 14 | ||
days-before-pr-close: -1 | ||
exempt-issue-labels: 'blocked,must,should,keep,pinned,work-in-progress,request,announcement' | ||
close-issue-message: 'This issue has been marked stale for 14 days and will now be closed. If this issue is still valid, please ping a maintainer.' | ||
- name: Print outputs | ||
run: echo ${{ join(steps.stale.outputs.*, ',') }} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
name: Sonarqube Scan | ||
agent: | ||
type: Unity::metal::macmini | ||
image: package-ci/mac | ||
flavor: m1.mac | ||
variables: | ||
PROJECT_PATH: TestUrdfImporter | ||
SONARQUBE_PROJECT_KEY: ai-robotics-urdf-importer | ||
SONARQUBE_PROJECT_BASE_DIR: /Users/bokken/build/output/Unity-Technologies/URDF-Importer/com.unity.robotics.urdf-importer | ||
MSBUILD_SLN_PATH: ./TestUrdfImporter/TestUrdfImporter.sln | ||
UNITY_VERSION: 2020.3.11f1 | ||
commands: | ||
- npm install upm-ci-utils@stable -g --registry https://artifactory.prd.it.unity3d.com/artifactory/api/npm/upm-npm | ||
- unity-downloader-cli -u $UNITY_VERSION -c Editor | ||
- brew install mono corretto | ||
- curl https://github.com/SonarSource/sonar-scanner-msbuild/releases/download/5.2.1.31210/sonar-scanner-msbuild-5.2.1.31210-net46.zip -o sonar-scanner-msbuild-net46.zip -L | ||
- unzip sonar-scanner-msbuild-net46.zip -d ~ | ||
- chmod a+x ~/sonar-scanner-4.6.1.2450/bin/sonar-scanner | ||
- .Editor/Unity.app/Contents/MacOS/Unity -projectPath $PROJECT_PATH -batchmode -quit -nographics -logFile - -executeMethod "UnityEditor.SyncVS.SyncSolution" | ||
- command: | | ||
cd $PROJECT_PATH | ||
for file in *.csproj; do sed -i.backup "s/^[[:blank:]]*<ReferenceOutputAssembly>false<\/ReferenceOutputAssembly>/<ReferenceOutputAssembly>true<\/ReferenceOutputAssembly>/g" $file; rm $file.backup; done | ||
cd ../ | ||
- mono ~/SonarScanner.MSBuild.exe begin /k:$SONARQUBE_PROJECT_KEY /d:sonar.host.url=$SONARQUBE_ENDPOINT_URL_PRD /d:sonar.login=$SONARQUBE_TOKEN_PRD /d:sonar.projectBaseDir=$SONARQUBE_PROJECT_BASE_DIR | ||
- msbuild $MSBUILD_SLN_PATH | ||
- mono ~/SonarScanner.MSBuild.exe end /d:sonar.login=$SONARQUBE_TOKEN_PRD | ||
triggers: | ||
cancel_old_ci: true | ||
expression: | | ||
((pull_request.target eq "main" OR pull_request.target eq "dev") | ||
AND NOT pull_request.push.changes.all match "**/*.md") OR | ||
(push.branch eq "main" OR push.branch eq "dev") | ||
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -30,24 +30,30 @@ does the following: | |
- Has corresponding changes to documentation, unit tests and sample environments (if | ||
applicable) | ||
- Contains a summary of the tests performed to validate your changes | ||
- Updates the [Changelog](com.unity.robotics.urdf-importer/CHANGELOG.md) and describes changes in the Unreleased section | ||
- Links to issue numbers that the PR resolves (if any) | ||
|
||
## Workflow | ||
|
||
This project is provided as a package to be imported into a Unity project. In order to avoid common issues regarding version control and unmanaged files, the suggested workflow for contributing to the package is as follows: | ||
|
||
1. Clone this repository to a known location on your local machine (e.g. Documents). | ||
2. Git checkout the `dev` branch to ensure you have the latest staged changes. | ||
3. In a development Unity project (e.g. a new project created from the Unity Hub of the minimum Unity [version](README.md) or above), open the `Window > Package Manager`. | ||
4. Click the `+` in the top-left of the Package Manager window and select `Add package from disk...`. | ||
5. Navigate to the cloned repository, and select the `com.unity.<package>/package.json` file. Click `Open`. | ||
6. The local version of the package is now added to your Unity project! Changes made to your cloned directory will update in your Unity project. | ||
|
||
<!-- ## Continuous Integration (CI) | ||
We run continuous integration on all PRs; all tests must be passing before the PR is merged. --> | ||
|
||
## Code style | ||
|
||
All Python code should follow the [PEP 8 style guidelines](https://pep8.org/). | ||
|
||
All C# code should follow the [Microsoft C# Coding Conventions](https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/inside-a-program/coding-conventions). | ||
Additionally, the [Unity Coding package](https://docs.unity3d.com/Packages/[email protected]/manual/index.html) | ||
can be used to format, encode, and lint your code according to the standard Unity | ||
development conventions. Be aware that these Unity conventions will supersede the | ||
Microsoft C# Coding Conventions where applicable. | ||
All C# code should follow the [Microsoft C# Coding Conventions](https://docs.microsoft.com/en-us/dotnet/csharp/programming-guide/inside-a-program/coding-conventions). (Code may be reformatted to Unity coding standards where applicable.) | ||
|
||
Please note that even if the code you are changing does not adhere to these guidelines, | ||
we expect your submissions to follow these conventions. | ||
Please note that even if the code you are changing does not follow these conventions, | ||
we expect your submissions to do so. | ||
|
||
## Contributor License Agreements | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.