diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml new file mode 100644 index 0000000..ee27812 --- /dev/null +++ b/.github/workflows/build.yaml @@ -0,0 +1,68 @@ +name: build release packages on os + +on: + workflow_dispatch: {} + push: + tags: v* + pull_request: {} + +# https://cli.github.com/manual/gh_release +# https://docs.github.com/en/actions/using-workflows/using-github-cli-in-workflows +jobs: + create-release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - name: gh create release + run: | + gh release delete ${{ github.ref_name }} --yes + gh release create --latest ${{ github.ref_name }} + env: + GH_TOKEN: ${{ secrets.ACTION_TOKEN }} + + # apparently you can't remove v0.1.0.tar.gz and v0.1.0.zip source archives + # - name: gh remove sources + # run: | + # gh release delete-asset ${{ github.ref_name }} ${{ github.ref_name }}.zip --yes + # gh release delete-asset ${{ github.ref_name }} ${{ github.ref_name }}.tar.gz --yes + # env: + # GH_TOKEN: ${{ secrets.ACTION_TOKEN }} + + release: + needs: create-release + name: build ${{ matrix.target }} + strategy: + fail-fast: false + matrix: + include: + - target: x86_64-pc-windows-gnu + runs-on: windows-latest + # - target: x86_64-unknown-linux-musl + # runs-on: ubuntu-latest + - target: x86_64-unknown-linux-gnu + runs-on: ubuntu-latest + - target: x86_64-apple-darwin + runs-on: macos-latest + + runs-on: ${{ matrix.runs-on }} + steps: + - uses: actions/checkout@v4 + - name: compile + run: cargo build --release + + - name: upload bin to release + if: ${{ runner.os != 'Windows' }} + run: | + cp target/release/jch jch-${{ matrix.target }}-${{ github.ref_name}} + gh release upload ${{ github.ref_name}} jch-${{ matrix.target }}-${{ github.ref_name}} + env: + GH_TOKEN: ${{ secrets.ACTION_TOKEN }} + + # also handle windows .exe files + - name: upload exe to release + if: ${{ runner.os == 'Windows' }} + run: | + cp target/release/jch.exe jch-${{ matrix.target }}-${{ github.ref_name}}.exe + gh release upload ${{ github.ref_name}} jch-${{ matrix.target }}-${{ github.ref_name}}.exe + env: + GH_TOKEN: ${{ secrets.ACTION_TOKEN }} diff --git a/.github/workflows/manual-build.yml.bak b/.github/workflows/manual-build.yml.bak new file mode 100644 index 0000000..14ecc33 --- /dev/null +++ b/.github/workflows/manual-build.yml.bak @@ -0,0 +1,54 @@ +# To trigger via rest api: +# curl -H "Authorization: token $GITHUB_TOKEN" -d "{\"ref\": \"your-branch-here\"}" https://api.github.com/repos/djellemah/jch/actions/workflows/build.yml/dispatches + +name: run tests then build release + +# on: +# workflow_dispatch: {} +# push: +# tags: v* +# branches: [test-build] +# pull_request: {} + +jobs: + build: + runs-on: ubuntu-latest + + env: {} + + steps: + - uses: actions/checkout@v4 + + - name: set up git credentials for cargo + run: | + mkdir -p $XDG_CONFIG_HOME/git + echo https://${{ secrets.ACTION_USER }}:${{ secrets.ACTION_TOKEN }}@github.com > $XDG_CONFIG_HOME/git/credentials + git config --global credential.helper store + git config --global --add credential.https://github.com.helper store + git config --global --add credential.https://github.com.username ${{ secrets.ACTION_USER }} + + - name: cache setup + uses: Swatinem/rust-cache@v2 + + - run: cargo build --tests + + release: + if: ${{ startsWith(github.ref, 'refs/tags/') }} + runs-on: ubuntu-latest + needs: build + + steps: + - uses: actions/checkout@v4 + + - name: setup cache + uses: Swatinem/rust-cache@v2 + + - run: cargo build --tests + + - name: package + uses: softprops/action-gh-release@v1 + if: startsWith(github.ref, 'refs/tags/') + env: + GITHUB_TOKEN: ${{ secrets.ACTION_TOKEN }} + with: + files: target/release/jch diff --git a/.github/workflows/rust-build.yaml.bak b/.github/workflows/rust-build.yaml.bak new file mode 100644 index 0000000..765ec85 --- /dev/null +++ b/.github/workflows/rust-build.yaml.bak @@ -0,0 +1,41 @@ +name: rust-build release packages + +# on: +# workflow_dispatch: {} +# push: +# tags: v* +# branches: [test-build] +# pull_request: {} + +jobs: + release: + name: build ${{ matrix.target }} + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + include: + - target: x86_64-pc-windows-gnu + archive: zip + - target: x86_64-unknown-linux-musl + archive: tar.gz + - target: x86_64-unknown-linux-gnu + archive: tar.gz + - target: x86_64-apple-darwin + archive: zip + steps: + - uses: actions/checkout@master + - name: Compile and release + uses: rust-build/rust-build.action@master + env: + GITHUB_TOKEN: ${{ secrets.ACTION_TOKEN }} + with: + RUSTTARGET: ${{ matrix.target }} + ARCHIVE_TYPES: ${{ matrix.archive }} + - name: Upload artifact + uses: actions/upload-artifact@v3 + with: + name: Binary + path: | + ${{ steps.compile.outputs.BUILT_ARCHIVE }} + ${{ steps.compile.outputs.BUILT_CHECKSUM }} diff --git a/README.md b/README.md index 1c14f1b..6e4bfea 100644 --- a/README.md +++ b/README.md @@ -10,17 +10,24 @@ For example: Currently only outputs the schema of a json file, in a non-standard format. -Is designed in a modular way so you can use it as a base for filtering json. Like `jq`. +Is designed in a modular way so you can use it as a base for filtering json. Somewhat like `jq`. -Might grow some kind of path-filtering languages, like jsonpath or xpath. +Might grow into some kind of path-filtering languages, like jsonpath or xpath. -# usage example +# Download a release + +See releases on the right of this repo page. Executables for linux, windows, macos. + +# How to build + +If there's no executable to suit you, you'll need to build your own: Clone this repo. ``` bash cargo build --release ``` +# Usage example ``` bash curl \ @@ -44,631 +51,9 @@ Number(Unsigned(9285252)):3245 []/org/id String(11):3245 []/org/login String(39):3245 []/org/url String(7):3314 []/payload/action -String(40):5815 []/payload/before -String(60):136 []/payload/comment/_links/html/href -String(50):136 []/payload/comment/_links/pull_request/href -String(66):136 []/payload/comment/_links/self/href -String(33):1053 []/payload/comment/body -String(40):209 []/payload/comment/commit_id -String(20):1053 []/payload/comment/created_at -String(54):136 []/payload/comment/diff_hunk -String(64):1053 []/payload/comment/html_url -Number(Unsigned(68488497)):1053 []/payload/comment/id -String(52):844 []/payload/comment/issue_url -[Number(Unsigned(896)):32,Null:41] []/payload/comment/line -String(40):136 []/payload/comment/original_commit_id -Number(Unsigned(4)):136 []/payload/comment/original_position -[Null:10,String(7):199] []/payload/comment/path -[Number(Unsigned(4)):164,Null:45] []/payload/comment/position -String(50):136 []/payload/comment/pull_request_url -String(20):1053 []/payload/comment/updated_at -String(68):1053 []/payload/comment/url -String(51):1053 []/payload/comment/user/avatar_url -String(53):1053 []/payload/comment/user/events_url -String(46):1053 []/payload/comment/user/followers_url -String(59):1053 []/payload/comment/user/following_url -String(52):1053 []/payload/comment/user/gists_url -String(0):1053 []/payload/comment/user/gravatar_id -String(26):1053 []/payload/comment/user/html_url -Number(Unsigned(7356386)):1053 []/payload/comment/user/id -String(7):1053 []/payload/comment/user/login -String(41):1053 []/payload/comment/user/organizations_url -String(52):1053 []/payload/comment/user/received_events_url -String(42):1053 []/payload/comment/user/repos_url -Boolean:1053 []/payload/comment/user/site_admin -String(59):1053 []/payload/comment/user/starred_url -String(50):1053 []/payload/comment/user/subscriptions_url -String(4):1053 []/payload/comment/user/type -String(36):1053 []/payload/comment/user/url -String(48):10109 []/payload/commits/[]/author/email -String(4):10109 []/payload/commits/[]/author/name -Boolean:10109 []/payload/commits/[]/distinct -String(32):10109 []/payload/commits/[]/message -String(40):10109 []/payload/commits/[]/sha -String(93):10109 []/payload/commits/[]/url -[String(109):1435,Null:36] []/payload/description -Number(Unsigned(1)):5815 []/payload/distinct_size -String(85):355 []/payload/forkee/archive_url -String(79):355 []/payload/forkee/assignees_url -String(78):355 []/payload/forkee/blobs_url -String(80):355 []/payload/forkee/branches_url -String(56):355 []/payload/forkee/clone_url -String(91):355 []/payload/forkee/collaborators_url -String(80):355 []/payload/forkee/comments_url -String(76):355 []/payload/forkee/commits_url -String(86):355 []/payload/forkee/compare_url -String(79):355 []/payload/forkee/contents_url -String(75):355 []/payload/forkee/contributors_url -String(20):355 []/payload/forkee/created_at -String(6):355 []/payload/forkee/default_branch -[String(106):351,Null:4] []/payload/forkee/description -String(72):355 []/payload/forkee/downloads_url -String(69):355 []/payload/forkee/events_url -Boolean:355 []/payload/forkee/fork -Number(Unsigned(0)):355 []/payload/forkee/forks -Number(Unsigned(0)):355 []/payload/forkee/forks_count -String(68):355 []/payload/forkee/forks_url -String(33):355 []/payload/forkee/full_name -String(80):355 []/payload/forkee/git_commits_url -String(77):355 []/payload/forkee/git_refs_url -String(77):355 []/payload/forkee/git_tags_url -String(54):355 []/payload/forkee/git_url -Boolean:355 []/payload/forkee/has_downloads -Boolean:355 []/payload/forkee/has_issues -Boolean:355 []/payload/forkee/has_pages -Boolean:355 []/payload/forkee/has_wiki -[Null:142,String(31):213] []/payload/forkee/homepage -String(68):355 []/payload/forkee/hooks_url -String(52):355 []/payload/forkee/html_url -Number(Unsigned(28688599)):355 []/payload/forkee/id -String(87):355 []/payload/forkee/issue_comment_url -String(85):355 []/payload/forkee/issue_events_url -String(78):355 []/payload/forkee/issues_url -String(76):355 []/payload/forkee/keys_url -String(76):355 []/payload/forkee/labels_url -[String(4):10,Null:345] []/payload/forkee/language -String(72):355 []/payload/forkee/languages_url -String(69):355 []/payload/forkee/merges_url -String(82):355 []/payload/forkee/milestones_url -Null:355 []/payload/forkee/mirror_url -String(25):355 []/payload/forkee/name -String(102):355 []/payload/forkee/notifications_url -Number(Unsigned(0)):355 []/payload/forkee/open_issues -Number(Unsigned(0)):355 []/payload/forkee/open_issues_count -String(51):355 []/payload/forkee/owner/avatar_url -String(53):355 []/payload/forkee/owner/events_url -String(46):355 []/payload/forkee/owner/followers_url -String(59):355 []/payload/forkee/owner/following_url -String(52):355 []/payload/forkee/owner/gists_url -String(0):355 []/payload/forkee/owner/gravatar_id -String(26):355 []/payload/forkee/owner/html_url -Number(Unsigned(1757814)):355 []/payload/forkee/owner/id -String(7):355 []/payload/forkee/owner/login -String(41):355 []/payload/forkee/owner/organizations_url -String(52):355 []/payload/forkee/owner/received_events_url -String(42):355 []/payload/forkee/owner/repos_url -Boolean:355 []/payload/forkee/owner/site_admin -String(59):355 []/payload/forkee/owner/starred_url -String(50):355 []/payload/forkee/owner/subscriptions_url -String(4):355 []/payload/forkee/owner/type -String(36):355 []/payload/forkee/owner/url -Boolean:355 []/payload/forkee/private -Boolean:355 []/payload/forkee/public -String(77):355 []/payload/forkee/pulls_url -String(20):355 []/payload/forkee/pushed_at -String(76):355 []/payload/forkee/releases_url -Number(Unsigned(259)):355 []/payload/forkee/size -String(52):355 []/payload/forkee/ssh_url -Number(Unsigned(0)):355 []/payload/forkee/stargazers_count -String(73):355 []/payload/forkee/stargazers_url -String(77):355 []/payload/forkee/statuses_url -String(74):355 []/payload/forkee/subscribers_url -String(75):355 []/payload/forkee/subscription_url -String(52):355 []/payload/forkee/svn_url -String(67):355 []/payload/forkee/tags_url -String(68):355 []/payload/forkee/teams_url -String(78):355 []/payload/forkee/trees_url -String(20):355 []/payload/forkee/updated_at -String(62):355 []/payload/forkee/url -Number(Unsigned(0)):355 []/payload/forkee/watchers -Number(Unsigned(0)):355 []/payload/forkee/watchers_count -String(40):5815 []/payload/head -Null:1220 []/payload/issue/assignee -String(51):169 []/payload/issue/assignee/avatar_url -String(54):169 []/payload/issue/assignee/events_url -String(47):169 []/payload/issue/assignee/followers_url -String(60):169 []/payload/issue/assignee/following_url -String(53):169 []/payload/issue/assignee/gists_url -String(0):169 []/payload/issue/assignee/gravatar_id -String(27):169 []/payload/issue/assignee/html_url -Number(Unsigned(6839081)):169 []/payload/issue/assignee/id -String(8):169 []/payload/issue/assignee/login -String(42):169 []/payload/issue/assignee/organizations_url -String(53):169 []/payload/issue/assignee/received_events_url -String(43):169 []/payload/issue/assignee/repos_url -Boolean:169 []/payload/issue/assignee/site_admin -String(60):169 []/payload/issue/assignee/starred_url -String(51):169 []/payload/issue/assignee/subscriptions_url -String(4):169 []/payload/issue/assignee/type -String(37):169 []/payload/issue/assignee/url -[Null:1,String(168):1388] []/payload/issue/body -[String(20):417,Null:972] []/payload/issue/closed_at -Number(Unsigned(0)):1389 []/payload/issue/comments -String(67):1389 []/payload/issue/comments_url -String(20):1389 []/payload/issue/created_at -String(65):1389 []/payload/issue/events_url -String(48):1389 []/payload/issue/html_url -Number(Unsigned(53221333)):1389 []/payload/issue/id -String(6):641 []/payload/issue/labels/[]/color -String(12):641 []/payload/issue/labels/[]/name -String(63):641 []/payload/issue/labels/[]/url -String(72):1389 []/payload/issue/labels_url -Boolean:1389 []/payload/issue/locked -Null:1252 []/payload/issue/milestone -[Null:135,String(20):2] []/payload/issue/milestone/closed_at -Number(Unsigned(9)):137 []/payload/issue/milestone/closed_issues -String(20):137 []/payload/issue/milestone/created_at -String(51):137 []/payload/issue/milestone/creator/avatar_url -String(53):137 []/payload/issue/milestone/creator/events_url -String(46):137 []/payload/issue/milestone/creator/followers_url -String(59):137 []/payload/issue/milestone/creator/following_url -String(52):137 []/payload/issue/milestone/creator/gists_url -String(0):137 []/payload/issue/milestone/creator/gravatar_id -String(26):137 []/payload/issue/milestone/creator/html_url -Number(Unsigned(6339799)):137 []/payload/issue/milestone/creator/id -String(7):137 []/payload/issue/milestone/creator/login -String(41):137 []/payload/issue/milestone/creator/organizations_url -String(52):137 []/payload/issue/milestone/creator/received_events_url -String(42):137 []/payload/issue/milestone/creator/repos_url -Boolean:137 []/payload/issue/milestone/creator/site_admin -String(59):137 []/payload/issue/milestone/creator/starred_url -String(50):137 []/payload/issue/milestone/creator/subscriptions_url -String(4):137 []/payload/issue/milestone/creator/type -String(36):137 []/payload/issue/milestone/creator/url -[String(0):112,Null:25] []/payload/issue/milestone/description -[Null:94,String(20):43] []/payload/issue/milestone/due_on -Number(Unsigned(917346)):137 []/payload/issue/milestone/id -String(76):137 []/payload/issue/milestone/labels_url -Number(Unsigned(3)):137 []/payload/issue/milestone/number -Number(Unsigned(1)):137 []/payload/issue/milestone/open_issues -String(4):137 []/payload/issue/milestone/state -String(5):137 []/payload/issue/milestone/title -String(20):137 []/payload/issue/milestone/updated_at -String(69):137 []/payload/issue/milestone/url -Number(Unsigned(27)):1389 []/payload/issue/number -String(47):313 []/payload/issue/pull_request/diff_url -String(42):313 []/payload/issue/pull_request/html_url -String(48):313 []/payload/issue/pull_request/patch_url -String(53):313 []/payload/issue/pull_request/url -String(4):1389 []/payload/issue/state -String(35):1389 []/payload/issue/title -String(20):1389 []/payload/issue/updated_at -String(58):1389 []/payload/issue/url -String(51):1389 []/payload/issue/user/avatar_url -String(54):1389 []/payload/issue/user/events_url -String(47):1389 []/payload/issue/user/followers_url -String(60):1389 []/payload/issue/user/following_url -String(53):1389 []/payload/issue/user/gists_url -String(0):1389 []/payload/issue/user/gravatar_id -String(27):1389 []/payload/issue/user/html_url -Number(Unsigned(6269456)):1389 []/payload/issue/user/id -String(8):1389 []/payload/issue/user/login -String(42):1389 []/payload/issue/user/organizations_url -String(53):1389 []/payload/issue/user/received_events_url -String(43):1389 []/payload/issue/user/repos_url -Boolean:1389 []/payload/issue/user/site_admin -String(60):1389 []/payload/issue/user/starred_url -String(51):1389 []/payload/issue/user/subscriptions_url -String(4):1389 []/payload/issue/user/type -String(37):1389 []/payload/issue/user/url -String(6):1471 []/payload/master_branch -String(51):25 []/payload/member/avatar_url -String(53):25 []/payload/member/events_url -String(46):25 []/payload/member/followers_url -String(59):25 []/payload/member/following_url -String(52):25 []/payload/member/gists_url -String(0):25 []/payload/member/gravatar_id -String(26):25 []/payload/member/html_url -Number(Unsigned(7234857)):25 []/payload/member/id -String(7):25 []/payload/member/login -String(41):25 []/payload/member/organizations_url -String(52):25 []/payload/member/received_events_url -String(42):25 []/payload/member/repos_url -Boolean:25 []/payload/member/site_admin -String(59):25 []/payload/member/starred_url -String(50):25 []/payload/member/subscriptions_url -String(4):25 []/payload/member/type -String(36):25 []/payload/member/url -Number(Unsigned(260)):474 []/payload/number -String(6):81 []/payload/pages/[]/action -String(56):81 []/payload/pages/[]/html_url -String(4):81 []/payload/pages/[]/page_name -String(40):81 []/payload/pages/[]/sha -Null:81 []/payload/pages/[]/summary -String(4):81 []/payload/pages/[]/title -String(69):610 []/payload/pull_request/_links/comments/href -String(67):610 []/payload/pull_request/_links/commits/href -String(48):610 []/payload/pull_request/_links/html/href -String(60):610 []/payload/pull_request/_links/issue/href -String(73):610 []/payload/pull_request/_links/review_comment/href -String(68):610 []/payload/pull_request/_links/review_comments/href -String(59):610 []/payload/pull_request/_links/self/href -String(99):610 []/payload/pull_request/_links/statuses/href -Number(Unsigned(2)):474 []/payload/pull_request/additions -Null:526 []/payload/pull_request/assignee -String(50):84 []/payload/pull_request/assignee/avatar_url -String(54):84 []/payload/pull_request/assignee/events_url -String(47):84 []/payload/pull_request/assignee/followers_url -String(60):84 []/payload/pull_request/assignee/following_url -String(53):84 []/payload/pull_request/assignee/gists_url -String(0):84 []/payload/pull_request/assignee/gravatar_id -String(27):84 []/payload/pull_request/assignee/html_url -Number(Unsigned(732452)):84 []/payload/pull_request/assignee/id -String(8):84 []/payload/pull_request/assignee/login -String(42):84 []/payload/pull_request/assignee/organizations_url -String(53):84 []/payload/pull_request/assignee/received_events_url -String(43):84 []/payload/pull_request/assignee/repos_url -Boolean:84 []/payload/pull_request/assignee/site_admin -String(60):84 []/payload/pull_request/assignee/starred_url -String(51):84 []/payload/pull_request/assignee/subscriptions_url -String(4):84 []/payload/pull_request/assignee/type -String(37):84 []/payload/pull_request/assignee/url -String(18):610 []/payload/pull_request/base/label -String(6):610 []/payload/pull_request/base/ref -String(72):610 []/payload/pull_request/base/repo/archive_url -String(66):610 []/payload/pull_request/base/repo/assignees_url -String(65):610 []/payload/pull_request/base/repo/blobs_url -String(67):610 []/payload/pull_request/base/repo/branches_url -String(43):610 []/payload/pull_request/base/repo/clone_url -String(78):610 []/payload/pull_request/base/repo/collaborators_url -String(67):610 []/payload/pull_request/base/repo/comments_url -String(63):610 []/payload/pull_request/base/repo/commits_url -String(73):610 []/payload/pull_request/base/repo/compare_url -String(66):610 []/payload/pull_request/base/repo/contents_url -String(62):610 []/payload/pull_request/base/repo/contributors_url -String(20):610 []/payload/pull_request/base/repo/created_at -String(6):610 []/payload/pull_request/base/repo/default_branch -String(106):610 []/payload/pull_request/base/repo/description -String(59):610 []/payload/pull_request/base/repo/downloads_url -String(56):610 []/payload/pull_request/base/repo/events_url -Boolean:610 []/payload/pull_request/base/repo/fork -Number(Unsigned(298)):610 []/payload/pull_request/base/repo/forks -Number(Unsigned(298)):610 []/payload/pull_request/base/repo/forks_count -String(55):610 []/payload/pull_request/base/repo/forks_url -String(20):610 []/payload/pull_request/base/repo/full_name -String(67):610 []/payload/pull_request/base/repo/git_commits_url -String(64):610 []/payload/pull_request/base/repo/git_refs_url -String(64):610 []/payload/pull_request/base/repo/git_tags_url -String(41):610 []/payload/pull_request/base/repo/git_url -Boolean:610 []/payload/pull_request/base/repo/has_downloads -Boolean:610 []/payload/pull_request/base/repo/has_issues -Boolean:610 []/payload/pull_request/base/repo/has_pages -Boolean:610 []/payload/pull_request/base/repo/has_wiki -[String(0):357,Null:253] []/payload/pull_request/base/repo/homepage -String(55):610 []/payload/pull_request/base/repo/hooks_url -String(39):610 []/payload/pull_request/base/repo/html_url -Number(Unsigned(3542607)):610 []/payload/pull_request/base/repo/id -String(74):610 []/payload/pull_request/base/repo/issue_comment_url -String(72):610 []/payload/pull_request/base/repo/issue_events_url -String(65):610 []/payload/pull_request/base/repo/issues_url -String(63):610 []/payload/pull_request/base/repo/keys_url -String(63):610 []/payload/pull_request/base/repo/labels_url -[String(3):553,Null:57] []/payload/pull_request/base/repo/language -String(59):610 []/payload/pull_request/base/repo/languages_url -String(56):610 []/payload/pull_request/base/repo/merges_url -String(69):610 []/payload/pull_request/base/repo/milestones_url -[String(30):1,Null:609] []/payload/pull_request/base/repo/mirror_url -String(8):610 []/payload/pull_request/base/repo/name -String(89):610 []/payload/pull_request/base/repo/notifications_url -Number(Unsigned(39)):610 []/payload/pull_request/base/repo/open_issues -Number(Unsigned(39)):610 []/payload/pull_request/base/repo/open_issues_count -String(50):610 []/payload/pull_request/base/repo/owner/avatar_url -String(57):610 []/payload/pull_request/base/repo/owner/events_url -String(50):610 []/payload/pull_request/base/repo/owner/followers_url -String(63):610 []/payload/pull_request/base/repo/owner/following_url -String(56):610 []/payload/pull_request/base/repo/owner/gists_url -String(0):610 []/payload/pull_request/base/repo/owner/gravatar_id -String(30):610 []/payload/pull_request/base/repo/owner/html_url -Number(Unsigned(699925)):610 []/payload/pull_request/base/repo/owner/id -String(11):610 []/payload/pull_request/base/repo/owner/login -String(45):610 []/payload/pull_request/base/repo/owner/organizations_url -String(56):610 []/payload/pull_request/base/repo/owner/received_events_url -String(46):610 []/payload/pull_request/base/repo/owner/repos_url -Boolean:610 []/payload/pull_request/base/repo/owner/site_admin -String(63):610 []/payload/pull_request/base/repo/owner/starred_url -String(54):610 []/payload/pull_request/base/repo/owner/subscriptions_url -String(4):610 []/payload/pull_request/base/repo/owner/type -String(40):610 []/payload/pull_request/base/repo/owner/url -Boolean:610 []/payload/pull_request/base/repo/private -String(64):610 []/payload/pull_request/base/repo/pulls_url -String(20):610 []/payload/pull_request/base/repo/pushed_at -String(63):610 []/payload/pull_request/base/repo/releases_url -Number(Unsigned(2559)):610 []/payload/pull_request/base/repo/size -String(39):610 []/payload/pull_request/base/repo/ssh_url -Number(Unsigned(648)):610 []/payload/pull_request/base/repo/stargazers_count -String(60):610 []/payload/pull_request/base/repo/stargazers_url -String(64):610 []/payload/pull_request/base/repo/statuses_url -String(61):610 []/payload/pull_request/base/repo/subscribers_url -String(62):610 []/payload/pull_request/base/repo/subscription_url -String(39):610 []/payload/pull_request/base/repo/svn_url -String(54):610 []/payload/pull_request/base/repo/tags_url -String(55):610 []/payload/pull_request/base/repo/teams_url -String(65):610 []/payload/pull_request/base/repo/trees_url -String(20):610 []/payload/pull_request/base/repo/updated_at -String(49):610 []/payload/pull_request/base/repo/url -Number(Unsigned(648)):610 []/payload/pull_request/base/repo/watchers -Number(Unsigned(648)):610 []/payload/pull_request/base/repo/watchers_count -String(40):610 []/payload/pull_request/base/sha -String(50):610 []/payload/pull_request/base/user/avatar_url -String(57):610 []/payload/pull_request/base/user/events_url -String(50):610 []/payload/pull_request/base/user/followers_url -String(63):610 []/payload/pull_request/base/user/following_url -String(56):610 []/payload/pull_request/base/user/gists_url -String(0):610 []/payload/pull_request/base/user/gravatar_id -String(30):610 []/payload/pull_request/base/user/html_url -Number(Unsigned(699925)):610 []/payload/pull_request/base/user/id -String(11):610 []/payload/pull_request/base/user/login -String(45):610 []/payload/pull_request/base/user/organizations_url -String(56):610 []/payload/pull_request/base/user/received_events_url -String(46):610 []/payload/pull_request/base/user/repos_url -Boolean:610 []/payload/pull_request/base/user/site_admin -String(63):610 []/payload/pull_request/base/user/starred_url -String(54):610 []/payload/pull_request/base/user/subscriptions_url -String(4):610 []/payload/pull_request/base/user/type -String(40):610 []/payload/pull_request/base/user/url -[String(105):601,Null:9] []/payload/pull_request/body -Number(Unsigned(1)):474 []/payload/pull_request/changed_files -[Null:381,String(20):229] []/payload/pull_request/closed_at -Number(Unsigned(0)):474 []/payload/pull_request/comments -String(69):610 []/payload/pull_request/comments_url -Number(Unsigned(1)):474 []/payload/pull_request/commits -String(67):610 []/payload/pull_request/commits_url -String(20):610 []/payload/pull_request/created_at -Number(Unsigned(3)):474 []/payload/pull_request/deletions -String(53):610 []/payload/pull_request/diff_url -String(39):610 []/payload/pull_request/head/label -String(29):610 []/payload/pull_request/head/ref -Null:3 []/payload/pull_request/head/repo -String(70):607 []/payload/pull_request/head/repo/archive_url -String(64):607 []/payload/pull_request/head/repo/assignees_url -String(63):607 []/payload/pull_request/head/repo/blobs_url -String(65):607 []/payload/pull_request/head/repo/branches_url -String(41):607 []/payload/pull_request/head/repo/clone_url -String(76):607 []/payload/pull_request/head/repo/collaborators_url -String(65):607 []/payload/pull_request/head/repo/comments_url -String(61):607 []/payload/pull_request/head/repo/commits_url -String(71):607 []/payload/pull_request/head/repo/compare_url -String(64):607 []/payload/pull_request/head/repo/contents_url -String(60):607 []/payload/pull_request/head/repo/contributors_url -String(20):607 []/payload/pull_request/head/repo/created_at -String(6):607 []/payload/pull_request/head/repo/default_branch -String(106):607 []/payload/pull_request/head/repo/description -String(57):607 []/payload/pull_request/head/repo/downloads_url -String(54):607 []/payload/pull_request/head/repo/events_url -Boolean:607 []/payload/pull_request/head/repo/fork -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/forks -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/forks_count -String(53):607 []/payload/pull_request/head/repo/forks_url -String(18):607 []/payload/pull_request/head/repo/full_name -String(65):607 []/payload/pull_request/head/repo/git_commits_url -String(62):607 []/payload/pull_request/head/repo/git_refs_url -String(62):607 []/payload/pull_request/head/repo/git_tags_url -String(39):607 []/payload/pull_request/head/repo/git_url -Boolean:607 []/payload/pull_request/head/repo/has_downloads -Boolean:607 []/payload/pull_request/head/repo/has_issues -Boolean:607 []/payload/pull_request/head/repo/has_pages -Boolean:607 []/payload/pull_request/head/repo/has_wiki -[Null:263,String(0):344] []/payload/pull_request/head/repo/homepage -String(53):607 []/payload/pull_request/head/repo/hooks_url -String(37):607 []/payload/pull_request/head/repo/html_url -Number(Unsigned(22466434)):607 []/payload/pull_request/head/repo/id -String(72):607 []/payload/pull_request/head/repo/issue_comment_url -String(70):607 []/payload/pull_request/head/repo/issue_events_url -String(63):607 []/payload/pull_request/head/repo/issues_url -String(61):607 []/payload/pull_request/head/repo/keys_url -String(61):607 []/payload/pull_request/head/repo/labels_url -[String(3):550,Null:57] []/payload/pull_request/head/repo/language -String(57):607 []/payload/pull_request/head/repo/languages_url -String(54):607 []/payload/pull_request/head/repo/merges_url -String(67):607 []/payload/pull_request/head/repo/milestones_url -Null:607 []/payload/pull_request/head/repo/mirror_url -String(8):607 []/payload/pull_request/head/repo/name -String(87):607 []/payload/pull_request/head/repo/notifications_url -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/open_issues -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/open_issues_count -String(51):607 []/payload/pull_request/head/repo/owner/avatar_url -String(55):607 []/payload/pull_request/head/repo/owner/events_url -String(48):607 []/payload/pull_request/head/repo/owner/followers_url -String(61):607 []/payload/pull_request/head/repo/owner/following_url -String(54):607 []/payload/pull_request/head/repo/owner/gists_url -String(0):607 []/payload/pull_request/head/repo/owner/gravatar_id -String(28):607 []/payload/pull_request/head/repo/owner/html_url -Number(Unsigned(1277095)):607 []/payload/pull_request/head/repo/owner/id -String(9):607 []/payload/pull_request/head/repo/owner/login -String(43):607 []/payload/pull_request/head/repo/owner/organizations_url -String(54):607 []/payload/pull_request/head/repo/owner/received_events_url -String(44):607 []/payload/pull_request/head/repo/owner/repos_url -Boolean:607 []/payload/pull_request/head/repo/owner/site_admin -String(61):607 []/payload/pull_request/head/repo/owner/starred_url -String(52):607 []/payload/pull_request/head/repo/owner/subscriptions_url -String(4):607 []/payload/pull_request/head/repo/owner/type -String(38):607 []/payload/pull_request/head/repo/owner/url -Boolean:607 []/payload/pull_request/head/repo/private -String(62):607 []/payload/pull_request/head/repo/pulls_url -String(20):607 []/payload/pull_request/head/repo/pushed_at -String(61):607 []/payload/pull_request/head/repo/releases_url -Number(Unsigned(1904)):607 []/payload/pull_request/head/repo/size -String(37):607 []/payload/pull_request/head/repo/ssh_url -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/stargazers_count -String(58):607 []/payload/pull_request/head/repo/stargazers_url -String(62):607 []/payload/pull_request/head/repo/statuses_url -String(59):607 []/payload/pull_request/head/repo/subscribers_url -String(60):607 []/payload/pull_request/head/repo/subscription_url -String(37):607 []/payload/pull_request/head/repo/svn_url -String(52):607 []/payload/pull_request/head/repo/tags_url -String(53):607 []/payload/pull_request/head/repo/teams_url -String(63):607 []/payload/pull_request/head/repo/trees_url -String(20):607 []/payload/pull_request/head/repo/updated_at -String(47):607 []/payload/pull_request/head/repo/url -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/watchers -Number(Unsigned(0)):607 []/payload/pull_request/head/repo/watchers_count -String(40):610 []/payload/pull_request/head/sha -String(51):610 []/payload/pull_request/head/user/avatar_url -String(55):610 []/payload/pull_request/head/user/events_url -String(48):610 []/payload/pull_request/head/user/followers_url -String(61):610 []/payload/pull_request/head/user/following_url -String(54):610 []/payload/pull_request/head/user/gists_url -String(0):610 []/payload/pull_request/head/user/gravatar_id -String(28):610 []/payload/pull_request/head/user/html_url -Number(Unsigned(1277095)):610 []/payload/pull_request/head/user/id -String(9):610 []/payload/pull_request/head/user/login -String(43):610 []/payload/pull_request/head/user/organizations_url -String(54):610 []/payload/pull_request/head/user/received_events_url -String(44):610 []/payload/pull_request/head/user/repos_url -Boolean:610 []/payload/pull_request/head/user/site_admin -String(61):610 []/payload/pull_request/head/user/starred_url -String(52):610 []/payload/pull_request/head/user/subscriptions_url -String(4):610 []/payload/pull_request/head/user/type -String(38):610 []/payload/pull_request/head/user/url -String(48):610 []/payload/pull_request/html_url -Number(Unsigned(26743765)):610 []/payload/pull_request/id -String(60):610 []/payload/pull_request/issue_url -Boolean:610 []/payload/pull_request/locked -[String(40):377,Null:233] []/payload/pull_request/merge_commit_sha -[Null:417,Boolean:57] []/payload/pull_request/mergeable -String(7):474 []/payload/pull_request/mergeable_state -Boolean:474 []/payload/pull_request/merged -[Null:433,String(20):177] []/payload/pull_request/merged_at -Null:299 []/payload/pull_request/merged_by -String(51):175 []/payload/pull_request/merged_by/avatar_url -String(57):175 []/payload/pull_request/merged_by/events_url -String(50):175 []/payload/pull_request/merged_by/followers_url -String(63):175 []/payload/pull_request/merged_by/following_url -String(56):175 []/payload/pull_request/merged_by/gists_url -String(0):175 []/payload/pull_request/merged_by/gravatar_id -String(30):175 []/payload/pull_request/merged_by/html_url -Number(Unsigned(2362917)):175 []/payload/pull_request/merged_by/id -String(11):175 []/payload/pull_request/merged_by/login -String(45):175 []/payload/pull_request/merged_by/organizations_url -String(56):175 []/payload/pull_request/merged_by/received_events_url -String(46):175 []/payload/pull_request/merged_by/repos_url -Boolean:175 []/payload/pull_request/merged_by/site_admin -String(63):175 []/payload/pull_request/merged_by/starred_url -String(54):175 []/payload/pull_request/merged_by/subscriptions_url -String(4):175 []/payload/pull_request/merged_by/type -String(40):175 []/payload/pull_request/merged_by/url -Null:568 []/payload/pull_request/milestone -Null:42 []/payload/pull_request/milestone/closed_at -Number(Unsigned(51)):42 []/payload/pull_request/milestone/closed_issues -String(20):42 []/payload/pull_request/milestone/created_at -String(50):42 []/payload/pull_request/milestone/creator/avatar_url -String(55):42 []/payload/pull_request/milestone/creator/events_url -String(48):42 []/payload/pull_request/milestone/creator/followers_url -String(61):42 []/payload/pull_request/milestone/creator/following_url -String(54):42 []/payload/pull_request/milestone/creator/gists_url -String(0):42 []/payload/pull_request/milestone/creator/gravatar_id -String(28):42 []/payload/pull_request/milestone/creator/html_url -Number(Unsigned(199813)):42 []/payload/pull_request/milestone/creator/id -String(9):42 []/payload/pull_request/milestone/creator/login -String(43):42 []/payload/pull_request/milestone/creator/organizations_url -String(54):42 []/payload/pull_request/milestone/creator/received_events_url -String(44):42 []/payload/pull_request/milestone/creator/repos_url -Boolean:42 []/payload/pull_request/milestone/creator/site_admin -String(61):42 []/payload/pull_request/milestone/creator/starred_url -String(52):42 []/payload/pull_request/milestone/creator/subscriptions_url -String(4):42 []/payload/pull_request/milestone/creator/type -String(38):42 []/payload/pull_request/milestone/creator/url -[Null:36,String(26):6] []/payload/pull_request/milestone/description -[String(20):1,Null:41] []/payload/pull_request/milestone/due_on -Number(Unsigned(830260)):42 []/payload/pull_request/milestone/id -String(71):42 []/payload/pull_request/milestone/labels_url -Number(Unsigned(17)):42 []/payload/pull_request/milestone/number -Number(Unsigned(24)):42 []/payload/pull_request/milestone/open_issues -String(4):42 []/payload/pull_request/milestone/state -String(6):42 []/payload/pull_request/milestone/title -String(20):42 []/payload/pull_request/milestone/updated_at -String(64):42 []/payload/pull_request/milestone/url -Number(Unsigned(260)):610 []/payload/pull_request/number -String(54):610 []/payload/pull_request/patch_url -String(73):610 []/payload/pull_request/review_comment_url -Number(Unsigned(0)):474 []/payload/pull_request/review_comments -String(68):610 []/payload/pull_request/review_comments_url -String(4):610 []/payload/pull_request/state -String(99):610 []/payload/pull_request/statuses_url -String(38):610 []/payload/pull_request/title -String(20):610 []/payload/pull_request/updated_at -String(59):610 []/payload/pull_request/url -String(51):610 []/payload/pull_request/user/avatar_url -String(55):610 []/payload/pull_request/user/events_url -String(48):610 []/payload/pull_request/user/followers_url -String(61):610 []/payload/pull_request/user/following_url -String(54):610 []/payload/pull_request/user/gists_url -String(0):610 []/payload/pull_request/user/gravatar_id -String(28):610 []/payload/pull_request/user/html_url -Number(Unsigned(1277095)):610 []/payload/pull_request/user/id -String(9):610 []/payload/pull_request/user/login -String(43):610 []/payload/pull_request/user/organizations_url -String(54):610 []/payload/pull_request/user/received_events_url -String(44):610 []/payload/pull_request/user/repos_url -Boolean:610 []/payload/pull_request/user/site_admin -String(61):610 []/payload/pull_request/user/starred_url -String(52):610 []/payload/pull_request/user/subscriptions_url -String(4):610 []/payload/pull_request/user/type -String(38):610 []/payload/pull_request/user/url -Number(Unsigned(536863970)):5815 []/payload/push_id -String(4):1731 []/payload/pusher_type -[String(6):6959,Null:587] []/payload/ref -String(6):1731 []/payload/ref_type -String(88):19 []/payload/release/assets/[]/browser_download_url -String(15):19 []/payload/release/assets/[]/content_type -String(20):19 []/payload/release/assets/[]/created_at -Number(Unsigned(0)):19 []/payload/release/assets/[]/download_count -Number(Unsigned(362298)):19 []/payload/release/assets/[]/id -[Null:16,String(0):3] []/payload/release/assets/[]/label -String(24):19 []/payload/release/assets/[]/name -Number(Unsigned(37781)):19 []/payload/release/assets/[]/size -String(8):19 []/payload/release/assets/[]/state -String(20):19 []/payload/release/assets/[]/updated_at -String(51):19 []/payload/release/assets/[]/uploader/avatar_url -String(57):19 []/payload/release/assets/[]/uploader/events_url -String(50):19 []/payload/release/assets/[]/uploader/followers_url -String(63):19 []/payload/release/assets/[]/uploader/following_url -String(56):19 []/payload/release/assets/[]/uploader/gists_url -String(0):19 []/payload/release/assets/[]/uploader/gravatar_id -String(30):19 []/payload/release/assets/[]/uploader/html_url -Number(Unsigned(7659931)):19 []/payload/release/assets/[]/uploader/id -String(11):19 []/payload/release/assets/[]/uploader/login -String(45):19 []/payload/release/assets/[]/uploader/organizations_url -String(56):19 []/payload/release/assets/[]/uploader/received_events_url -String(46):19 []/payload/release/assets/[]/uploader/repos_url -Boolean:19 []/payload/release/assets/[]/uploader/site_admin -String(63):19 []/payload/release/assets/[]/uploader/starred_url -String(54):19 []/payload/release/assets/[]/uploader/subscriptions_url -String(4):19 []/payload/release/assets/[]/uploader/type -String(40):19 []/payload/release/assets/[]/uploader/url -String(71):19 []/payload/release/assets/[]/url -String(71):60 []/payload/release/assets_url -String(51):60 []/payload/release/author/avatar_url -String(57):60 []/payload/release/author/events_url -String(50):60 []/payload/release/author/followers_url -String(63):60 []/payload/release/author/following_url -String(56):60 []/payload/release/author/gists_url -String(0):60 []/payload/release/author/gravatar_id -String(30):60 []/payload/release/author/html_url -Number(Unsigned(7659931)):60 []/payload/release/author/id -String(11):60 []/payload/release/author/login -String(45):60 []/payload/release/author/organizations_url -String(56):60 []/payload/release/author/received_events_url -String(46):60 []/payload/release/author/repos_url -Boolean:60 []/payload/release/author/site_admin -String(63):60 []/payload/release/author/starred_url -String(54):60 []/payload/release/author/subscriptions_url -String(4):60 []/payload/release/author/type -String(40):60 []/payload/release/author/url -[String(0):59,Null:1] []/payload/release/body -String(20):60 []/payload/release/created_at -Boolean:60 []/payload/release/draft -String(58):60 []/payload/release/html_url +… +… +… Number(Unsigned(818676)):60 []/payload/release/id [String(0):59,Null:1] []/payload/release/name Boolean:60 []/payload/release/prerelease @@ -687,3 +72,22 @@ String(42):11351 []/repo/url String(11):11351 []/type ``` +## Interpreting the output + +The fundamental perspective here is that a tree is a map of paths to values, and the schema of a tree is a map from the paths to the types of those values. + +Right hand column is the path, excluding numeric indexes (ie arrays). You'll still see `[]` where arrays would be. + +Left hand column is the aggregated type of all leaves at the path in the right-hand column. That is, for the corresponding path on the right, the value had these characteristics: + +- `String(n)` means the largest string encountered has length `n` + +- `Unsigned(n)` means n was the largest value encountered + +- `Signed(min,max)` means min and max encountered + +- `Float(min,max)` means min and max encountered + +- `Xxx:nnnn` means `nnnn` was the number of values encountered, ie the number of leaf nodes matching the path. + +- If more than one type was encountered at the path, the left hand column will contain an array of characteristics, as above. That is, it's a sum type.