From 43a598966f2e0b98b5ad06c3e80d9d864faac41d Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 30 Jun 2020 14:56:24 -0700 Subject: [PATCH 01/24] Update Program.cs --- csharp/src/Program.cs | 1 + 1 file changed, 1 insertion(+) diff --git a/csharp/src/Program.cs b/csharp/src/Program.cs index 0613f9c..4450b73 100644 --- a/csharp/src/Program.cs +++ b/csharp/src/Program.cs @@ -6,6 +6,7 @@ class Program { static void Main(string[] args) { + Console.WriteLine("hello!"); Interactive block = new GameObject(10, 10); block.interact(); } From e44b42abd16ca60fb12cd199ae00ec24a8240d55 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Wed, 1 Jul 2020 14:33:08 -0700 Subject: [PATCH 02/24] Update GameObject.ts --- typescript/src/GameObject.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/typescript/src/GameObject.ts b/typescript/src/GameObject.ts index d529293..3a27d76 100644 --- a/typescript/src/GameObject.ts +++ b/typescript/src/GameObject.ts @@ -16,5 +16,6 @@ export default class GameObject implements Drawable, Interactive { draw(): void { console.log(`Drawing GameObject at position: ${this.posX} ${this.posY}`); + console.log('hi, mom!!'); } -} \ No newline at end of file +} From 21df570e4707c4c762fb0393528b0f14407ecd96 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:05:54 -0700 Subject: [PATCH 03/24] Add first workflow templates --- .github/workflows/richnav-csharp.yml | 33 ++++++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/richnav-csharp.yml diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml new file mode 100644 index 0000000..27765aa --- /dev/null +++ b/.github/workflows/richnav-csharp.yml @@ -0,0 +1,33 @@ +### This template is meant to be used by a .NET Core repository running RichNav +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository +name: Rich Code Navigation (.NET Core) + +on: + push: + branches: [ master ] + pull_request: + +jobs: + build: + + runs-on: windows-latest + + steps: + + - uses: actions/checkout@v2 + + # **** Please change 'dotnet-version' to be the version of the .NET SDK used in your project **** # + - name: Setup .NET Core + uses: actions/setup-dotnet@v1 + with: + dotnet-version: 3.1.101 + + # **** Please change 'working-directory' to be the location where your .SLN file is located **** # + - name: Install dependencies + run: dotnet restore + working-directory: ./DemoApp + + - uses: microsoft/RichCodeNavIndexer@v0.1 + with: + languages: csharp + repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From f1f6e2c292ec5c52211826b11bb3123da911078d Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:30:15 -0700 Subject: [PATCH 04/24] Add typescript action --- .github/workflows/richnav-typescript.yml | 33 ++++++++++++++++++++++++ 1 file changed, 33 insertions(+) create mode 100644 .github/workflows/richnav-typescript.yml diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml new file mode 100644 index 0000000..0871566 --- /dev/null +++ b/.github/workflows/richnav-typescript.yml @@ -0,0 +1,33 @@ +### This template is meant to be used by a .NET Core repository running RichNav +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository + +name: Rich Code Navigation (Node JS) + +on: + push: + branches: [ master ] + pull_request: + +jobs: + richnav: + + runs-on: windows-latest + + # **** If necessary, use the Node version for your repository. Note: must be greater than 10.x **** # + strategy: + matrix: + node-version: [10.x, 12.x, 14.x] + + steps: + - uses: actions/checkout@v2 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v1 + with: + node-version: ${{ matrix.node-version }} + - run: npm ci + + - uses: microsoft/RichCodeNavIndexer@master + with: + languages: typescript + repo-token: ${{ secrets.GITHUB_TOKEN }} + From 2eb92d05ba162d625216f2ddac93ec797ebea6bf Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:12:18 -0700 Subject: [PATCH 05/24] Update richnav-csharp.yml --- .github/workflows/richnav-csharp.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index 27765aa..4399c35 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -25,9 +25,9 @@ jobs: # **** Please change 'working-directory' to be the location where your .SLN file is located **** # - name: Install dependencies run: dotnet restore - working-directory: ./DemoApp + working-directory: ./csharp - uses: microsoft/RichCodeNavIndexer@v0.1 with: languages: csharp - repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + repo-token: ${{ secrets.GITHUB_TOKEN }} From 0cbba6c1950c21cdf28b5a8c6d8cf74345e4d7d3 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:20:12 -0700 Subject: [PATCH 06/24] Use master of rich nav task --- .github/workflows/richnav-csharp.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index 4399c35..f79cfda 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -27,7 +27,7 @@ jobs: run: dotnet restore working-directory: ./csharp - - uses: microsoft/RichCodeNavIndexer@v0.1 + - uses: microsoft/RichCodeNavIndexer@master with: languages: csharp repo-token: ${{ secrets.GITHUB_TOKEN }} From 692abecd91e3e23b389e2cd3c123fbf6509009e1 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:34:47 -0700 Subject: [PATCH 07/24] Add java workflow --- .github/workflows/richnav-java.yml | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 .github/workflows/richnav-java.yml diff --git a/.github/workflows/richnav-java.yml b/.github/workflows/richnav-java.yml new file mode 100644 index 0000000..9a4cd55 --- /dev/null +++ b/.github/workflows/richnav-java.yml @@ -0,0 +1,27 @@ +### This template is meant to be used by a .NET Core repository running RichNav +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository + +name: Rich Code Navigation (Java with Maven) + +on: + push: + branches: [ master ] + pull_request: + +jobs: + richnav: + + runs-on: windows-latest + + steps: + - uses: actions/checkout@v2 + + - name: Set up JDK 1.8 + uses: actions/setup-java@v1 + with: + java-version: 1.8 + + - uses: microsoft/RichCodeNavIndexer@master + with: + languages: java + repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From b75b1aeadd3cfc84fd13dabe5da7b1fcd7482af8 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 14:41:58 -0700 Subject: [PATCH 08/24] Fix typescript action --- .github/workflows/richnav-typescript.yml | 4 +++- .gitignore | 1 + typescript/package.json | 10 ++++++++++ typescript/yarn.lock | 4 ++++ 4 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 typescript/package.json create mode 100644 typescript/yarn.lock diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index 0871566..86ffbd9 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -24,7 +24,9 @@ jobs: uses: actions/setup-node@v1 with: node-version: ${{ matrix.node-version }} - - run: npm ci + + - run: yarn + working-directory: typescript - uses: microsoft/RichCodeNavIndexer@master with: diff --git a/.gitignore b/.gitignore index 041046f..6053d9c 100644 --- a/.gitignore +++ b/.gitignore @@ -5,6 +5,7 @@ csharp/.vs/* # TypeScript typescript/lib +node_modules # Java java/lib \ No newline at end of file diff --git a/typescript/package.json b/typescript/package.json new file mode 100644 index 0000000..405365a --- /dev/null +++ b/typescript/package.json @@ -0,0 +1,10 @@ +{ + "name": "tester-game", + "version": "0.0.1", + "description": "A simple Typescript game to test things", + "main": "App.js", + "license": "MIT", + "scripts": { + "build": "tsc -p ./" + } +} \ No newline at end of file diff --git a/typescript/yarn.lock b/typescript/yarn.lock new file mode 100644 index 0000000..fb57ccd --- /dev/null +++ b/typescript/yarn.lock @@ -0,0 +1,4 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + From 829630f5b970b72038a14fea9a95a1216476bf79 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 15:39:46 -0700 Subject: [PATCH 09/24] Add new template for entire workflow --- .github/workflows/richnav-all.yml | 46 +++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) create mode 100644 .github/workflows/richnav-all.yml diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml new file mode 100644 index 0000000..da96ae2 --- /dev/null +++ b/.github/workflows/richnav-all.yml @@ -0,0 +1,46 @@ +### This template is meant to be used by a .NET Core repository running RichNav +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository + +name: Rich Code Navigation + +on: + push: + branches: [ master ] + pull_request: + +jobs: + richnav: + + runs-on: windows-latest + + steps: + - uses: actions/checkout@v2 + + # **** Please change 'dotnet-version' to be the version of the .NET SDK used in your project **** # + - name: Setup .NET Core + uses: actions/setup-dotnet@v1 + with: + dotnet-version: 3.1.101 + + # **** Please change 'working-directory' to be the location where your .SLN file is located **** # + - name: Install dependencies + run: dotnet restore + working-directory: ./csharp + + # **** Please change the version of Node being used to the one for your project **** # + - name: Use Node.js 12.x + uses: actions/setup-node@v1 + with: + node-version: 12.x + + - run: yarn + working-directory: typescript + + - name: Set up JDK 1.8 + uses: actions/setup-java@v1 + with: + java-version: 1.8 + + - uses: microsoft/RichCodeNavIndexer@v0.1 + with: + repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file From e3dfb32e502ad709772f7adf427f24aa47be3b20 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Thu, 9 Jul 2020 15:48:43 -0700 Subject: [PATCH 10/24] try specifying pull requests first --- .github/workflows/richnav-all.yml | 2 +- .github/workflows/richnav-csharp.yml | 2 +- .github/workflows/richnav-java.yml | 2 +- .github/workflows/richnav-typescript.yml | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index da96ae2..e08595d 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -4,9 +4,9 @@ name: Rich Code Navigation on: + pull_request: push: branches: [ master ] - pull_request: jobs: richnav: diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index f79cfda..2e06630 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -3,9 +3,9 @@ name: Rich Code Navigation (.NET Core) on: + pull_request: push: branches: [ master ] - pull_request: jobs: build: diff --git a/.github/workflows/richnav-java.yml b/.github/workflows/richnav-java.yml index 9a4cd55..f73281a 100644 --- a/.github/workflows/richnav-java.yml +++ b/.github/workflows/richnav-java.yml @@ -4,9 +4,9 @@ name: Rich Code Navigation (Java with Maven) on: + pull_request: push: branches: [ master ] - pull_request: jobs: richnav: diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index 86ffbd9..82a694a 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -4,9 +4,9 @@ name: Rich Code Navigation (Node JS) on: + pull_request: push: branches: [ master ] - pull_request: jobs: richnav: From 41d17e0678569baabea70a70ec8af544d605c9f1 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Mon, 13 Jul 2020 08:10:49 -0700 Subject: [PATCH 11/24] Explicitly list languages, use v0.1 for all --- .github/workflows/richnav-all.yml | 3 ++- .github/workflows/richnav-csharp.yml | 2 +- .github/workflows/richnav-java.yml | 2 +- .github/workflows/richnav-typescript.yml | 2 +- 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index e08595d..44f0313 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -43,4 +43,5 @@ jobs: - uses: microsoft/RichCodeNavIndexer@v0.1 with: - repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file + repo-token: ${{ secrets.GITHUB_TOKEN }} + languages: csharp, java, typescript, cpp \ No newline at end of file diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index 2e06630..6d693b5 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -27,7 +27,7 @@ jobs: run: dotnet restore working-directory: ./csharp - - uses: microsoft/RichCodeNavIndexer@master + - uses: microsoft/RichCodeNavIndexer@v0.1 with: languages: csharp repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/richnav-java.yml b/.github/workflows/richnav-java.yml index f73281a..ae1406e 100644 --- a/.github/workflows/richnav-java.yml +++ b/.github/workflows/richnav-java.yml @@ -21,7 +21,7 @@ jobs: with: java-version: 1.8 - - uses: microsoft/RichCodeNavIndexer@master + - uses: microsoft/RichCodeNavIndexer@v0.1 with: languages: java repo-token: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index 82a694a..99fde22 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -28,7 +28,7 @@ jobs: - run: yarn working-directory: typescript - - uses: microsoft/RichCodeNavIndexer@master + - uses: microsoft/RichCodeNavIndexer@v0.1 with: languages: typescript repo-token: ${{ secrets.GITHUB_TOKEN }} From b59b9b223a8d3aaa489c2cfe0e92a37943395edb Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Mon, 13 Jul 2020 08:23:55 -0700 Subject: [PATCH 12/24] Fix typo --- .github/workflows/richnav-all.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index 44f0313..e47f1f2 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -44,4 +44,4 @@ jobs: - uses: microsoft/RichCodeNavIndexer@v0.1 with: repo-token: ${{ secrets.GITHUB_TOKEN }} - languages: csharp, java, typescript, cpp \ No newline at end of file + languages: csharp,java,typescript,cpp \ No newline at end of file From 06c1c80faab1fd6af12ecd318c8b517947382c25 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Mon, 13 Jul 2020 09:10:36 -0700 Subject: [PATCH 13/24] Update typescript restore steps --- .github/workflows/richnav-all.yml | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index e47f1f2..df447e0 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -33,8 +33,14 @@ jobs: with: node-version: 12.x + # **** Please update, at least, the working directory below. You may also want to use npm install instead **** # - run: yarn working-directory: typescript + + # **** If you use NPM to install packages, please uncomment this task and delete the yarn task **** # + # - name: npm install + # working-directory: typescript + # run: npm install - name: Set up JDK 1.8 uses: actions/setup-java@v1 @@ -44,4 +50,4 @@ jobs: - uses: microsoft/RichCodeNavIndexer@v0.1 with: repo-token: ${{ secrets.GITHUB_TOKEN }} - languages: csharp,java,typescript,cpp \ No newline at end of file + languages: csharp,java,typescript,cpp From 644d98a5d60c506c347fdcff0a91c7f4ddc6b6cd Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 4 Aug 2020 12:36:01 -0700 Subject: [PATCH 14/24] Update App.java --- java/src/main/java/com/test/sort/App.java | 1 + 1 file changed, 1 insertion(+) diff --git a/java/src/main/java/com/test/sort/App.java b/java/src/main/java/com/test/sort/App.java index f72a225..94c6bde 100644 --- a/java/src/main/java/com/test/sort/App.java +++ b/java/src/main/java/com/test/sort/App.java @@ -9,6 +9,7 @@ public class App public static void main( String[] args ) { System.out.println( "Hello World!" ); + System.out.println("Hiya!"); } } From bc672ee8ed56f4375d80f5547abb704c345631b1 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 1 Sep 2020 11:31:54 -0700 Subject: [PATCH 15/24] Update based on feedback from Etienne --- .github/workflows/richnav-all.yml | 8 +++++--- .github/workflows/richnav-csharp.yml | 7 ++++--- .github/workflows/richnav-java.yml | 5 +++-- .github/workflows/richnav-typescript.yml | 5 +++-- 4 files changed, 15 insertions(+), 10 deletions(-) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index df447e0..fe09145 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -1,4 +1,5 @@ -### This template is meant to be used by a .NET Core repository running RichNav +### This template is meant to be used by a multi-language repo running RichNav. +### It provides rich navigation for C#, JavaScript, TypeScript, C++, and Java ### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository name: Rich Code Navigation @@ -6,7 +7,8 @@ name: Rich Code Navigation on: pull_request: push: - branches: [ master ] + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] jobs: richnav: @@ -16,7 +18,7 @@ jobs: steps: - uses: actions/checkout@v2 - # **** Please change 'dotnet-version' to be the version of the .NET SDK used in your project **** # + # **** If you've defined a specific dotnet version in global.json, change 'dotnet-version' to the version of the .NET SDK used in your project **** # - name: Setup .NET Core uses: actions/setup-dotnet@v1 with: diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index 6d693b5..c384103 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -1,11 +1,12 @@ -### This template is meant to be used by a .NET Core repository running RichNav +### This template is meant to be used by a C# repository running RichNav ### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository name: Rich Code Navigation (.NET Core) on: pull_request: push: - branches: [ master ] + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] jobs: build: @@ -16,7 +17,7 @@ jobs: - uses: actions/checkout@v2 - # **** Please change 'dotnet-version' to be the version of the .NET SDK used in your project **** # + # **** If you've defined a specific dotnet version in global.json, change 'dotnet-version' to the version of the .NET SDK used in your project **** # - name: Setup .NET Core uses: actions/setup-dotnet@v1 with: diff --git a/.github/workflows/richnav-java.yml b/.github/workflows/richnav-java.yml index ae1406e..ff2e182 100644 --- a/.github/workflows/richnav-java.yml +++ b/.github/workflows/richnav-java.yml @@ -1,4 +1,4 @@ -### This template is meant to be used by a .NET Core repository running RichNav +### This template is meant to be used by a Java repository running RichNav ### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository name: Rich Code Navigation (Java with Maven) @@ -6,7 +6,8 @@ name: Rich Code Navigation (Java with Maven) on: pull_request: push: - branches: [ master ] + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] jobs: richnav: diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index 99fde22..ba4aaa6 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -1,4 +1,4 @@ -### This template is meant to be used by a .NET Core repository running RichNav +### This template is meant to be used by a TypeScript or JavaScript repository running RichNav ### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository name: Rich Code Navigation (Node JS) @@ -6,7 +6,8 @@ name: Rich Code Navigation (Node JS) on: pull_request: push: - branches: [ master ] + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] jobs: richnav: From e6aa74a2ae5bc614507ceb353559a667c3810025 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 1 Sep 2020 11:32:25 -0700 Subject: [PATCH 16/24] TEST: Only specify root directory --- .github/workflows/richnav-csharp.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index c384103..b6edd9b 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -26,7 +26,7 @@ jobs: # **** Please change 'working-directory' to be the location where your .SLN file is located **** # - name: Install dependencies run: dotnet restore - working-directory: ./csharp + working-directory: ./ - uses: microsoft/RichCodeNavIndexer@v0.1 with: From ee14cacf84f7dea01ce8cecb2eb4f348fa96065c Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 1 Sep 2020 12:14:03 -0700 Subject: [PATCH 17/24] Add multiple solution files example --- .../richnav-csharp-multiple-sln.yaml | 37 +++++++++++++++++++ .github/workflows/richnav-csharp.yml | 2 +- AnotherSolution/AnotherSolution.sln | 25 +++++++++++++ .../AnotherSolution/AnotherSolution.csproj | 8 ++++ AnotherSolution/AnotherSolution/Program.cs | 12 ++++++ 5 files changed, 83 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/richnav-csharp-multiple-sln.yaml create mode 100644 AnotherSolution/AnotherSolution.sln create mode 100644 AnotherSolution/AnotherSolution/AnotherSolution.csproj create mode 100644 AnotherSolution/AnotherSolution/Program.cs diff --git a/.github/workflows/richnav-csharp-multiple-sln.yaml b/.github/workflows/richnav-csharp-multiple-sln.yaml new file mode 100644 index 0000000..5c59353 --- /dev/null +++ b/.github/workflows/richnav-csharp-multiple-sln.yaml @@ -0,0 +1,37 @@ +### This template is meant to be used by a C# repository running RichNav +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository +name: Rich Code Navigation (.NET Core) + +on: + pull_request: + push: + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] + +jobs: + build: + + runs-on: windows-latest + strategy: + matrix: + # **** Please change the list to be the folders which contain solutions **** # + slnDirs: [ './csharp', './AnotherSolution' ] + + steps: + + - uses: actions/checkout@v2 + + # **** If you've defined a specific dotnet version in global.json, change 'dotnet-version' to the version of the .NET SDK used in your project **** # + - name: Setup .NET Core + uses: actions/setup-dotnet@v1 + with: + dotnet-version: 3.1.101 + + - name: Install dependencies + run: dotnet restore + working-directory: ${{ matrix.slnDirs }} + + - uses: microsoft/RichCodeNavIndexer@v0.1 + with: + languages: csharp + repo-token: ${{ secrets.GITHUB_TOKEN }} diff --git a/.github/workflows/richnav-csharp.yml b/.github/workflows/richnav-csharp.yml index b6edd9b..c384103 100644 --- a/.github/workflows/richnav-csharp.yml +++ b/.github/workflows/richnav-csharp.yml @@ -26,7 +26,7 @@ jobs: # **** Please change 'working-directory' to be the location where your .SLN file is located **** # - name: Install dependencies run: dotnet restore - working-directory: ./ + working-directory: ./csharp - uses: microsoft/RichCodeNavIndexer@v0.1 with: diff --git a/AnotherSolution/AnotherSolution.sln b/AnotherSolution/AnotherSolution.sln new file mode 100644 index 0000000..411d3f5 --- /dev/null +++ b/AnotherSolution/AnotherSolution.sln @@ -0,0 +1,25 @@ + +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.30426.262 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "AnotherSolution", "AnotherSolution\AnotherSolution.csproj", "{4343B1BF-A100-4951-90AD-42CB919F2895}" +EndProject +Global + GlobalSection(SolutionConfigurationPlatforms) = preSolution + Debug|Any CPU = Debug|Any CPU + Release|Any CPU = Release|Any CPU + EndGlobalSection + GlobalSection(ProjectConfigurationPlatforms) = postSolution + {4343B1BF-A100-4951-90AD-42CB919F2895}.Debug|Any CPU.ActiveCfg = Debug|Any CPU + {4343B1BF-A100-4951-90AD-42CB919F2895}.Debug|Any CPU.Build.0 = Debug|Any CPU + {4343B1BF-A100-4951-90AD-42CB919F2895}.Release|Any CPU.ActiveCfg = Release|Any CPU + {4343B1BF-A100-4951-90AD-42CB919F2895}.Release|Any CPU.Build.0 = Release|Any CPU + EndGlobalSection + GlobalSection(SolutionProperties) = preSolution + HideSolutionNode = FALSE + EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {CE15F879-CB32-4B6C-89A8-1C23E5920DEF} + EndGlobalSection +EndGlobal diff --git a/AnotherSolution/AnotherSolution/AnotherSolution.csproj b/AnotherSolution/AnotherSolution/AnotherSolution.csproj new file mode 100644 index 0000000..c73e0d1 --- /dev/null +++ b/AnotherSolution/AnotherSolution/AnotherSolution.csproj @@ -0,0 +1,8 @@ + + + + Exe + netcoreapp3.1 + + + diff --git a/AnotherSolution/AnotherSolution/Program.cs b/AnotherSolution/AnotherSolution/Program.cs new file mode 100644 index 0000000..6e4c684 --- /dev/null +++ b/AnotherSolution/AnotherSolution/Program.cs @@ -0,0 +1,12 @@ +using System; + +namespace AnotherSolution +{ + class Program + { + static void Main(string[] args) + { + Console.WriteLine("Another testing solution!"); + } + } +} From 60123246d0bbeccf463cfe4ba209f18ddaf3f7d2 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 1 Sep 2020 12:26:07 -0700 Subject: [PATCH 18/24] Add example of a scheduled run --- .../richnav-csharp-multiple-sln.yaml | 4 +- .github/workflows/richnav-scheduled.yaml | 39 +++++++++++++++++++ 2 files changed, 41 insertions(+), 2 deletions(-) create mode 100644 .github/workflows/richnav-scheduled.yaml diff --git a/.github/workflows/richnav-csharp-multiple-sln.yaml b/.github/workflows/richnav-csharp-multiple-sln.yaml index 5c59353..6bc51a6 100644 --- a/.github/workflows/richnav-csharp-multiple-sln.yaml +++ b/.github/workflows/richnav-csharp-multiple-sln.yaml @@ -1,6 +1,6 @@ -### This template is meant to be used by a C# repository running RichNav +### This template is meant to be used by a C# repository with multiple solutions running RichNav ### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository -name: Rich Code Navigation (.NET Core) +name: Rich Code Navigation (.NET Core - Multiple Solutions) on: pull_request: diff --git a/.github/workflows/richnav-scheduled.yaml b/.github/workflows/richnav-scheduled.yaml new file mode 100644 index 0000000..212cc2f --- /dev/null +++ b/.github/workflows/richnav-scheduled.yaml @@ -0,0 +1,39 @@ +### This template is meant to be used by a C# repository running RichNav on a scheduled cadence. +### This is particularly appropriate for reference repositories that aren't updated monthly. +### Please replace the C# specific steps with steps for your particular language +### Please fill anything marked above with a "# **** #" comment with the value appropriate for your repository +name: Rich Code Navigation (.NET Core) + +on: + schedule: + # **** This runs the action on the 14th of every month at midnight. Adjust the schedule as appropriate for your needs **** # + - cron: '0 14 * * 1' + pull_request: + push: + # **** Add any the name of your default branch, or any branch you want indexed on every push **** # + branches: [ main ] + +jobs: + build: + + runs-on: windows-latest + + steps: + + - uses: actions/checkout@v2 + + # **** If you've defined a specific dotnet version in global.json, change 'dotnet-version' to the version of the .NET SDK used in your project **** # + - name: Setup .NET Core + uses: actions/setup-dotnet@v1 + with: + dotnet-version: 3.1.101 + + # **** Please change 'working-directory' to be the location where your .SLN file is located **** # + - name: Install dependencies + run: dotnet restore + working-directory: ./csharp + + - uses: microsoft/RichCodeNavIndexer@v0.1 + with: + languages: csharp + repo-token: ${{ secrets.GITHUB_TOKEN }} From d9bf6cca086b3992c811324930397f0523634b05 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 1 Sep 2020 12:28:36 -0700 Subject: [PATCH 19/24] Remove other triggers from scheduled pipeline --- .github/workflows/richnav-scheduled.yaml | 4 ---- 1 file changed, 4 deletions(-) diff --git a/.github/workflows/richnav-scheduled.yaml b/.github/workflows/richnav-scheduled.yaml index 212cc2f..f6cc8fe 100644 --- a/.github/workflows/richnav-scheduled.yaml +++ b/.github/workflows/richnav-scheduled.yaml @@ -8,10 +8,6 @@ on: schedule: # **** This runs the action on the 14th of every month at midnight. Adjust the schedule as appropriate for your needs **** # - cron: '0 14 * * 1' - pull_request: - push: - # **** Add any the name of your default branch, or any branch you want indexed on every push **** # - branches: [ main ] jobs: build: From 5b121c6216eaf85f9ecd7ad40fcd561710e203f9 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Mon, 5 Oct 2020 16:50:55 -0700 Subject: [PATCH 20/24] Add example of caching dependencies --- .github/workflows/richnav-typescript.yml | 9 +++++++++ typescript/package.json | 6 +++++- typescript/src/GameObject.ts | 2 ++ typescript/yarn.lock | 4 ++++ 4 files changed, 20 insertions(+), 1 deletion(-) diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index ba4aaa6..353bed0 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -26,8 +26,17 @@ jobs: with: node-version: ${{ matrix.node-version }} + - uses: actions/cache@v2 + id: caching-stage + name: Cache dependencies + with: + path: node_modules + key: ${{ runner.os }}-dependencies-${{ hashfiles('typescript/yarn.lock') }} + restore-keys: ${{ runner.os }}-dependencies- + - run: yarn working-directory: typescript + if: steps.caching-stage.outputs.cache-hit != 'true' - uses: microsoft/RichCodeNavIndexer@v0.1 with: diff --git a/typescript/package.json b/typescript/package.json index 405365a..7b5361b 100644 --- a/typescript/package.json +++ b/typescript/package.json @@ -6,5 +6,9 @@ "license": "MIT", "scripts": { "build": "tsc -p ./" + }, + "dependencies": { + "@types/node": "^14.11.3", + "add-two-number": "^0.2.0" } -} \ No newline at end of file +} diff --git a/typescript/src/GameObject.ts b/typescript/src/GameObject.ts index 3a27d76..f76e0f9 100644 --- a/typescript/src/GameObject.ts +++ b/typescript/src/GameObject.ts @@ -1,5 +1,6 @@ import Drawable from './Drawable' import Interactive from './Interactive' +const add: any = require('add-two-number'); export default class GameObject implements Drawable, Interactive { posX: number; @@ -12,6 +13,7 @@ export default class GameObject implements Drawable, Interactive { interact(): void { console.log("Interacting with GameObject"); + console.log(`Adding two numbers: ${add(this.posX, this.posY)}`); } draw(): void { diff --git a/typescript/yarn.lock b/typescript/yarn.lock index fb57ccd..77e9bd2 100644 --- a/typescript/yarn.lock +++ b/typescript/yarn.lock @@ -2,3 +2,7 @@ # yarn lockfile v1 +add-two-number@^0.2.0: + version "0.2.0" + resolved "https://registry.yarnpkg.com/add-two-number/-/add-two-number-0.2.0.tgz#f21e52b3a328f3551b247489b4b0351465ef363e" + integrity sha512-zB+QIdul0cHNXAj1xVAhzhk8WQ8JvLYlp1L3kwZr3zIIgdV+U1kp4DkRJRqutvPgDl1jBG9TcbMU3cWgeY9d7w== From 2de459679b1c99270098e6afd05af4daabe9fdfc Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Mon, 5 Oct 2020 17:05:46 -0700 Subject: [PATCH 21/24] Fix a few more documentation problems --- .github/workflows/richnav-all.yml | 10 ++++++++++ .github/workflows/richnav-typescript.yml | 2 ++ 2 files changed, 12 insertions(+) diff --git a/.github/workflows/richnav-all.yml b/.github/workflows/richnav-all.yml index fe09145..a7bde27 100644 --- a/.github/workflows/richnav-all.yml +++ b/.github/workflows/richnav-all.yml @@ -35,9 +35,19 @@ jobs: with: node-version: 12.x + # **** Please update to point to the location where your node dependencies are installed **** # + - uses: actions/cache@v2 + id: caching-stage + name: Cache dependencies + with: + path: node_modules + key: ${{ runner.os }}-dependencies-${{ hashfiles('typescript/yarn.lock') }} + restore-keys: ${{ runner.os }}-dependencies- + # **** Please update, at least, the working directory below. You may also want to use npm install instead **** # - run: yarn working-directory: typescript + if: steps.caching-stage.outputs.cache-hit != 'true' # **** If you use NPM to install packages, please uncomment this task and delete the yarn task **** # # - name: npm install diff --git a/.github/workflows/richnav-typescript.yml b/.github/workflows/richnav-typescript.yml index 353bed0..590779c 100644 --- a/.github/workflows/richnav-typescript.yml +++ b/.github/workflows/richnav-typescript.yml @@ -26,6 +26,7 @@ jobs: with: node-version: ${{ matrix.node-version }} + # **** Please update to point to the location where your node dependencies are installed **** # - uses: actions/cache@v2 id: caching-stage name: Cache dependencies @@ -34,6 +35,7 @@ jobs: key: ${{ runner.os }}-dependencies-${{ hashfiles('typescript/yarn.lock') }} restore-keys: ${{ runner.os }}-dependencies- + # **** Please update the working-directory to the location where your package.json file resides **** # - run: yarn working-directory: typescript if: steps.caching-stage.outputs.cache-hit != 'true' From 30dea747263918de277f68a9eb578b94e131ad6a Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Tue, 6 Oct 2020 12:52:32 -0700 Subject: [PATCH 22/24] Update Block.ts --- typescript/src/Block.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/typescript/src/Block.ts b/typescript/src/Block.ts index e4aa2e1..126444b 100644 --- a/typescript/src/Block.ts +++ b/typescript/src/Block.ts @@ -6,6 +6,6 @@ export default class Block extends GameObject { } interact(): void { - console.log('You get a coin!'); + console.log('You get a coin, you rock star!'); } -} \ No newline at end of file +} From 91ca7236b9d68e8e5bf03c5efb81a9b87437231e Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Fri, 9 Oct 2020 09:37:35 -0700 Subject: [PATCH 23/24] Update GameObject.cs --- csharp/src/GameObject.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/csharp/src/GameObject.cs b/csharp/src/GameObject.cs index 9a2a382..e0916d2 100644 --- a/csharp/src/GameObject.cs +++ b/csharp/src/GameObject.cs @@ -15,6 +15,7 @@ public GameObject(int x, int y) public void interact() { Console.WriteLine("Interacting with GameObject"); + Console.WriteLine("Nice work! You rock!"); } public void draw() @@ -22,4 +23,4 @@ public void draw() Console.WriteLine($"Drawing GameObject at position: {this.posX} {this.posY}"); } } -} \ No newline at end of file +} From 1f043df9876498b21221de156fee81b816515744 Mon Sep 17 00:00:00 2001 From: Jessica Petty Date: Fri, 9 Oct 2020 09:56:16 -0700 Subject: [PATCH 24/24] Update Interactive.ts --- typescript/src/Interactive.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/typescript/src/Interactive.ts b/typescript/src/Interactive.ts index b142567..1e6083f 100644 --- a/typescript/src/Interactive.ts +++ b/typescript/src/Interactive.ts @@ -1,3 +1,4 @@ export default interface Interactive { + // interacts interact: () => void; -} \ No newline at end of file +}