Compare commits
45 Commits
Author | SHA1 | Date | |
---|---|---|---|
0b0e88c604 | |||
c48e27c649 | |||
dfa353c356 | |||
2f1209d1e0 | |||
195815fc8a | |||
4e393fdd57 | |||
75f14f7878 | |||
349640acc5 | |||
1d0eca90a7 | |||
81bb65db4e | |||
6295477ccf | |||
b7324b3b38 | |||
e90fb7f54c | |||
253de8cea2 | |||
bd014301fd | |||
45c0d26e33 | |||
0edceb6a7d | |||
056d798d61 | |||
96f2e9422c | |||
df19951729 | |||
bfc97dad32 | |||
d28ac95aa2 | |||
8a0df3e52c | |||
e2c42a5287 | |||
f638124930 | |||
9cabea63c3 | |||
20074ac4e1 | |||
0ec7bd93d8 | |||
c1a1af0109 | |||
2c0094670b | |||
58fdc32627 | |||
cbeca19467 | |||
4cc8bd4385 | |||
fac1efeb7d | |||
1abc2d6333 | |||
a69c523e3c | |||
766c67f723 | |||
2f70e42f9a | |||
763910b515 | |||
dca32e4317 | |||
c301978f0b | |||
97fcb5a420 | |||
724c49d056 | |||
7b5d225701 | |||
90fc0ee584 |
20
.github/workflows/nix-build.yml
vendored
Normal file
20
.github/workflows/nix-build.yml
vendored
Normal file
@ -0,0 +1,20 @@
|
||||
name: "Nix Build"
|
||||
|
||||
on: [push]
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- uses: actions/checkout@v2
|
||||
- uses: cachix/install-nix-action@v8
|
||||
- name: Cache nix store
|
||||
uses: actions/cache@v1
|
||||
with:
|
||||
path: /nix
|
||||
key: ${{ runner.os }}-nix-store
|
||||
- uses: cachix/cachix-action@v5
|
||||
with:
|
||||
name: hitsofcode
|
||||
signingKey: '${{ secrets.CACHIX_SIGNING_KEY }}'
|
||||
attributes: package
|
166
Cargo.lock
generated
166
Cargo.lock
generated
@ -12,7 +12,7 @@ dependencies = [
|
||||
"futures-sink",
|
||||
"log",
|
||||
"tokio",
|
||||
"tokio-util",
|
||||
"tokio-util 0.2.0",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -106,14 +106,16 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "actix-rt"
|
||||
version = "1.0.0"
|
||||
version = "1.1.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3f6a0a55507046441a496b2f0d26a84a65e67c8cafffe279072412f624b5fb6d"
|
||||
checksum = "143fcc2912e0d1de2bcf4e2f720d2a60c28652ab4179685a1ee159e0fb3db227"
|
||||
dependencies = [
|
||||
"actix-macros",
|
||||
"actix-threadpool",
|
||||
"copyless",
|
||||
"futures",
|
||||
"futures-channel",
|
||||
"futures-util",
|
||||
"smallvec",
|
||||
"tokio",
|
||||
]
|
||||
|
||||
@ -401,6 +403,12 @@ version = "0.11.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b41b7ea54a0c9d92199de89e20e58d49f02f8e699814ef3fdf266f6f748d15c7"
|
||||
|
||||
[[package]]
|
||||
name = "base64"
|
||||
version = "0.12.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7d5ca2cd0adc3f48f9e9ea5a6bbdf9ccc0bfade884847e484d452414c7ccffb3"
|
||||
|
||||
[[package]]
|
||||
name = "bitflags"
|
||||
version = "1.2.1"
|
||||
@ -667,9 +675,9 @@ checksum = "3dcaa9ae7725d12cdb85b3ad99a434db70b468c09ded17e012d86b5c1010f7a7"
|
||||
|
||||
[[package]]
|
||||
name = "futures"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5c329ae8753502fb44ae4fc2b622fa2a94652c41e795143765ba0927f92ab780"
|
||||
checksum = "1e05b85ec287aac0dc34db7d4a569323df697f9c55b99b15d6b4ef8cde49f613"
|
||||
dependencies = [
|
||||
"futures-channel",
|
||||
"futures-core",
|
||||
@ -682,9 +690,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "futures-channel"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f0c77d04ce8edd9cb903932b608268b3fffec4163dc053b3b402bf47eac1f1a8"
|
||||
checksum = "f366ad74c28cca6ba456d95e6422883cfb4b252a83bed929c83abfdbbf2967d5"
|
||||
dependencies = [
|
||||
"futures-core",
|
||||
"futures-sink",
|
||||
@ -692,15 +700,15 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "futures-core"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f25592f769825e89b92358db00d26f965761e094951ac44d3663ef25b7ac464a"
|
||||
checksum = "59f5fff90fd5d971f936ad674802482ba441b6f09ba5e15fd8b39145582ca399"
|
||||
|
||||
[[package]]
|
||||
name = "futures-executor"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f674f3e1bcb15b37284a90cedf55afdba482ab061c407a9c0ebbd0f3109741ba"
|
||||
checksum = "10d6bb888be1153d3abeb9006b11b02cf5e9b209fda28693c31ae1e4e012e314"
|
||||
dependencies = [
|
||||
"futures-core",
|
||||
"futures-task",
|
||||
@ -709,15 +717,15 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "futures-io"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a638959aa96152c7a4cddf50fcb1e3fede0583b27157c26e67d6f99904090dc6"
|
||||
checksum = "de27142b013a8e869c14957e6d2edeef89e97c289e69d042ee3a49acd8b51789"
|
||||
|
||||
[[package]]
|
||||
name = "futures-macro"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9a5081aa3de1f7542a794a397cde100ed903b0630152d0973479018fd85423a7"
|
||||
checksum = "d0b5a30a4328ab5473878237c447333c093297bded83a4983d10f4deea240d39"
|
||||
dependencies = [
|
||||
"proc-macro-hack",
|
||||
"proc-macro2",
|
||||
@ -727,21 +735,24 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "futures-sink"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3466821b4bc114d95b087b850a724c6f83115e929bc88f1fa98a3304a944c8a6"
|
||||
checksum = "3f2032893cb734c7a05d85ce0cc8b8c4075278e93b24b66f9de99d6eb0fa8acc"
|
||||
|
||||
[[package]]
|
||||
name = "futures-task"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "7b0a34e53cf6cdcd0178aa573aed466b646eb3db769570841fda0c7ede375a27"
|
||||
checksum = "bdb66b5f09e22019b1ab0830f7785bcea8e7a42148683f99214f73f8ec21a626"
|
||||
dependencies = [
|
||||
"once_cell",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "futures-util"
|
||||
version = "0.3.4"
|
||||
version = "0.3.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "22766cf25d64306bedf0384da004d05c9974ab104fcc4528f1236181c18004c5"
|
||||
checksum = "8764574ff08b701a084482c3c7031349104b07ac897393010494beaa18ce32c6"
|
||||
dependencies = [
|
||||
"futures-channel",
|
||||
"futures-core",
|
||||
@ -750,6 +761,7 @@ dependencies = [
|
||||
"futures-sink",
|
||||
"futures-task",
|
||||
"memchr",
|
||||
"pin-project",
|
||||
"pin-utils",
|
||||
"proc-macro-hack",
|
||||
"proc-macro-nested",
|
||||
@ -778,9 +790,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "git2"
|
||||
version = "0.13.0"
|
||||
version = "0.13.5"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b7da16ceafe24cedd9ba02c4463a2b506b6493baf4317c79c5acb553134a3c15"
|
||||
checksum = "e1e02a51cd90229028c9bd8be0a0364f85b6b3199cccaa0ef39005ddbd5ac165"
|
||||
dependencies = [
|
||||
"bitflags",
|
||||
"libc",
|
||||
@ -793,9 +805,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "h2"
|
||||
version = "0.2.1"
|
||||
version = "0.2.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b9433d71e471c1736fd5a61b671fc0b148d7a2992f666c958d03cd8feb3b88d1"
|
||||
checksum = "377038bf3c89d18d6ca1431e7a5027194fbd724ca10592b9487ede5e8e144f42"
|
||||
dependencies = [
|
||||
"bytes",
|
||||
"fnv",
|
||||
@ -807,7 +819,7 @@ dependencies = [
|
||||
"log",
|
||||
"slab",
|
||||
"tokio",
|
||||
"tokio-util",
|
||||
"tokio-util 0.3.1",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -830,7 +842,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "hoc"
|
||||
version = "0.11.6"
|
||||
version = "0.12.0"
|
||||
dependencies = [
|
||||
"actix-rt",
|
||||
"actix-web",
|
||||
@ -849,6 +861,7 @@ dependencies = [
|
||||
"serde_derive",
|
||||
"serde_json",
|
||||
"structopt",
|
||||
"tempfile",
|
||||
"vergen",
|
||||
]
|
||||
|
||||
@ -900,9 +913,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "hyper"
|
||||
version = "0.13.2"
|
||||
version = "0.13.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "fa1c527bbc634be72aa7ba31e4e4def9bbb020f5416916279b7c705cd838893e"
|
||||
checksum = "ed6081100e960d9d74734659ffc9cc91daf1c0fc7aceb8eaa94ee1a3f5046f2e"
|
||||
dependencies = [
|
||||
"bytes",
|
||||
"futures-channel",
|
||||
@ -978,9 +991,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "itertools"
|
||||
version = "0.8.2"
|
||||
version = "0.9.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "f56a2d0bc861f9165be4eb3442afd3c236d8a98afd426f65d92324ae1091a484"
|
||||
checksum = "284f18f85651fe11e8a991b2adb42cb078325c996ed026d994719efcfca1d54b"
|
||||
dependencies = [
|
||||
"either",
|
||||
]
|
||||
@ -1052,9 +1065,9 @@ checksum = "d515b1f41455adea1313a4a2ac8a8a477634fbae63cc6100e3aebb207ce61558"
|
||||
|
||||
[[package]]
|
||||
name = "libgit2-sys"
|
||||
version = "0.12.0+0.99.0"
|
||||
version = "0.12.5+1.0.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "05dff41ac39e7b653f5f1550886cf00ba52f8e7f57210b633cdeedb3de5b236c"
|
||||
checksum = "3eadeec65514971355bf7134967a543f71372f35b53ac6c7143e7bd157f07535"
|
||||
dependencies = [
|
||||
"cc",
|
||||
"libc",
|
||||
@ -1123,9 +1136,9 @@ checksum = "a94d21414c1f4a51209ad204c1776a3d0765002c76c6abcb602a6f09f1e881c7"
|
||||
|
||||
[[package]]
|
||||
name = "log4rs"
|
||||
version = "0.11.0"
|
||||
version = "0.12.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b47ba5437ccdf01e4addd4d2347ef561911d57f908f4db1e1b192d5c25a92715"
|
||||
checksum = "f4d8e6e1d5f89acca713132acc6034f30bad09b961d1338161bdb71c08f6e4fa"
|
||||
dependencies = [
|
||||
"arc-swap",
|
||||
"chrono",
|
||||
@ -1336,9 +1349,15 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "number_prefix"
|
||||
version = "0.3.0"
|
||||
version = "0.4.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "17b02fc0ff9a9e4b35b3342880f48e896ebf69f2967921fe8646bf5b7125956a"
|
||||
checksum = "830b246a0e5f20af87141b25c173cd1b609bd7779a4617d6ec582abaf90870f3"
|
||||
|
||||
[[package]]
|
||||
name = "once_cell"
|
||||
version = "1.3.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b1c601810575c99596d4afc46f78a678c80105117c379eb3650cf99b8a21ce5b"
|
||||
|
||||
[[package]]
|
||||
name = "openssl"
|
||||
@ -1450,9 +1469,9 @@ checksum = "237844750cfbb86f67afe27eee600dfbbcb6188d734139b534cbfbf4f96792ae"
|
||||
|
||||
[[package]]
|
||||
name = "pin-utils"
|
||||
version = "0.1.0-alpha.4"
|
||||
version = "0.1.0"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "5894c618ce612a3fa23881b152b608bafb8c56cfc22f434a3ba3120b40f7b587"
|
||||
checksum = "8b870d8c151b6f2fb93e84a13146138f05d02ed11c7e7c54f8826aaaf7c9f184"
|
||||
|
||||
[[package]]
|
||||
name = "pkg-config"
|
||||
@ -1468,28 +1487,28 @@ checksum = "74490b50b9fbe561ac330df47c08f3f33073d2d00c150f719147d7c54522fa1b"
|
||||
|
||||
[[package]]
|
||||
name = "proc-macro-error"
|
||||
version = "0.4.8"
|
||||
version = "1.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "875077759af22fa20b610ad4471d8155b321c89c3f2785526c9839b099be4e0a"
|
||||
checksum = "98e9e4b82e0ef281812565ea4751049f1bdcdfccda7d3f459f2e138a40c08678"
|
||||
dependencies = [
|
||||
"proc-macro-error-attr",
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"rustversion",
|
||||
"syn",
|
||||
"version_check 0.9.1",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "proc-macro-error-attr"
|
||||
version = "0.4.8"
|
||||
version = "1.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c5717d9fa2664351a01ed73ba5ef6df09c01a521cb42cb65a061432a826f3c7a"
|
||||
checksum = "4f5444ead4e9935abd7f27dc51f7e852a0569ac888096d5ec2499470794e2e53"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"rustversion",
|
||||
"syn",
|
||||
"syn-mid",
|
||||
"version_check 0.9.1",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
@ -1609,9 +1628,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "reqwest"
|
||||
version = "0.10.3"
|
||||
version = "0.10.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "a9f62f24514117d09a8fc74b803d3d65faa27cea1c7378fb12b0d002913f3831"
|
||||
checksum = "02b81e49ddec5109a9dcfc5f2a317ff53377c915e9ae9d4f2fb50914b85614e2"
|
||||
dependencies = [
|
||||
"base64 0.11.0",
|
||||
"bytes",
|
||||
@ -1654,11 +1673,11 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "ructe"
|
||||
version = "0.9.2"
|
||||
version = "0.11.4"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c85620b8046f88a870d93d90fa56904dec76cc79139bfcc22e71e87f0cd2169f"
|
||||
checksum = "f615d1e172dcc01a7cd78c7f77f21a5669c6de4341548ad2e7764e9045d06657"
|
||||
dependencies = [
|
||||
"base64 0.11.0",
|
||||
"base64 0.12.0",
|
||||
"bytecount",
|
||||
"itertools",
|
||||
"md5",
|
||||
@ -1691,17 +1710,6 @@ dependencies = [
|
||||
"stb_truetype 0.2.8",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "rustversion"
|
||||
version = "1.0.2"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "b3bba175698996010c4f6dce5e7f173b6eb781fce25d2cfc45e27091ce0b79f6"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
"syn",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "ryu"
|
||||
version = "1.0.2"
|
||||
@ -1768,9 +1776,9 @@ checksum = "388a1df253eca08550bef6c72392cfe7c30914bf41df5269b68cbd6ff8f570a3"
|
||||
|
||||
[[package]]
|
||||
name = "serde"
|
||||
version = "1.0.105"
|
||||
version = "1.0.110"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "e707fbbf255b8fc8c3b99abb91e7257a622caeb20a9818cbadbeeede4e0932ff"
|
||||
checksum = "99e7b308464d16b56eba9964e4972a3eee817760ab60d88c3f86e1fecb08204c"
|
||||
dependencies = [
|
||||
"serde_derive",
|
||||
]
|
||||
@ -1787,9 +1795,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "serde_derive"
|
||||
version = "1.0.105"
|
||||
version = "1.0.110"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "ac5d00fc561ba2724df6758a17de23df5914f20e41cb00f94d5b7ae42fffaff8"
|
||||
checksum = "818fbf6bfa9a42d3bfcaca148547aa00c7b915bec71d1757aa2d44ca68771984"
|
||||
dependencies = [
|
||||
"proc-macro2",
|
||||
"quote",
|
||||
@ -1798,9 +1806,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "serde_json"
|
||||
version = "1.0.48"
|
||||
version = "1.0.53"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "9371ade75d4c2d6cb154141b9752cf3781ec9c05e0e5cf35060e1e70ee7b9c25"
|
||||
checksum = "993948e75b189211a9b31a7528f950c6adc21f9720b6438ff80a7fa2f864cea2"
|
||||
dependencies = [
|
||||
"itoa",
|
||||
"ryu",
|
||||
@ -1909,9 +1917,9 @@ checksum = "8ea5119cdb4c55b55d432abb513a0429384878c15dde60cc77b1c99de1a95a6a"
|
||||
|
||||
[[package]]
|
||||
name = "structopt"
|
||||
version = "0.3.12"
|
||||
version = "0.3.14"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "c8faa2719539bbe9d77869bfb15d4ee769f99525e707931452c97b693b3f159d"
|
||||
checksum = "863246aaf5ddd0d6928dfeb1a9ca65f505599e4e1b399935ef7e75107516b4ef"
|
||||
dependencies = [
|
||||
"clap",
|
||||
"lazy_static",
|
||||
@ -1920,9 +1928,9 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "structopt-derive"
|
||||
version = "0.4.5"
|
||||
version = "0.4.7"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "3f88b8e18c69496aad6f9ddf4630dd7d585bcaf765786cb415b9aec2fe5a0430"
|
||||
checksum = "d239ca4b13aee7a2142e6795cbd69e457665ff8037aed33b3effdc430d2f927a"
|
||||
dependencies = [
|
||||
"heck",
|
||||
"proc-macro-error",
|
||||
@ -2073,6 +2081,20 @@ dependencies = [
|
||||
"tokio",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tokio-util"
|
||||
version = "0.3.1"
|
||||
source = "registry+https://github.com/rust-lang/crates.io-index"
|
||||
checksum = "be8242891f2b6cbef26a2d7e8605133c2c554cd35b3e4948ea892d6d68436499"
|
||||
dependencies = [
|
||||
"bytes",
|
||||
"futures-core",
|
||||
"futures-sink",
|
||||
"log",
|
||||
"pin-project-lite",
|
||||
"tokio",
|
||||
]
|
||||
|
||||
[[package]]
|
||||
name = "tower-service"
|
||||
version = "0.3.0"
|
||||
|
88
Cargo.nix
88
Cargo.nix
@ -27,7 +27,7 @@ in
|
||||
{
|
||||
cargo2nixVersion = "0.8.2";
|
||||
workspace = {
|
||||
hoc = rustPackages.unknown.hoc."0.11.5";
|
||||
hoc = rustPackages.unknown.hoc."0.11.8";
|
||||
};
|
||||
"registry+https://github.com/rust-lang/crates.io-index".actix-codec."0.2.0" = overridableMkRustCrate (profileName: rec {
|
||||
name = "actix-codec";
|
||||
@ -105,7 +105,7 @@ in
|
||||
futures_core = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-core."0.3.4" { inherit profileName; };
|
||||
futures_util = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-util."0.3.4" { inherit profileName; };
|
||||
fxhash = rustPackages."registry+https://github.com/rust-lang/crates.io-index".fxhash."0.2.1" { inherit profileName; };
|
||||
h2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".h2."0.2.1" { inherit profileName; };
|
||||
h2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".h2."0.2.4" { inherit profileName; };
|
||||
http = rustPackages."registry+https://github.com/rust-lang/crates.io-index".http."0.2.0" { inherit profileName; };
|
||||
httparse = rustPackages."registry+https://github.com/rust-lang/crates.io-index".httparse."1.3.4" { inherit profileName; };
|
||||
indexmap = rustPackages."registry+https://github.com/rust-lang/crates.io-index".indexmap."1.3.2" { inherit profileName; };
|
||||
@ -118,7 +118,7 @@ in
|
||||
rand = rustPackages."registry+https://github.com/rust-lang/crates.io-index".rand."0.7.3" { inherit profileName; };
|
||||
regex = rustPackages."registry+https://github.com/rust-lang/crates.io-index".regex."1.3.4" { inherit profileName; };
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
serde_urlencoded = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_urlencoded."0.6.1" { inherit profileName; };
|
||||
sha1 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".sha1."0.6.0" { inherit profileName; };
|
||||
slab = rustPackages."registry+https://github.com/rust-lang/crates.io-index".slab."0.4.2" { inherit profileName; };
|
||||
@ -309,7 +309,7 @@ in
|
||||
pin_project = rustPackages."registry+https://github.com/rust-lang/crates.io-index".pin-project."0.4.8" { inherit profileName; };
|
||||
regex = rustPackages."registry+https://github.com/rust-lang/crates.io-index".regex."1.3.4" { inherit profileName; };
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
serde_urlencoded = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_urlencoded."0.6.1" { inherit profileName; };
|
||||
time = rustPackages."registry+https://github.com/rust-lang/crates.io-index".time."0.1.42" { inherit profileName; };
|
||||
url = rustPackages."registry+https://github.com/rust-lang/crates.io-index".url."2.1.1" { inherit profileName; };
|
||||
@ -445,7 +445,7 @@ in
|
||||
percent_encoding = rustPackages."registry+https://github.com/rust-lang/crates.io-index".percent-encoding."2.1.0" { inherit profileName; };
|
||||
rand = rustPackages."registry+https://github.com/rust-lang/crates.io-index".rand."0.7.3" { inherit profileName; };
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
serde_urlencoded = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_urlencoded."0.6.1" { inherit profileName; };
|
||||
};
|
||||
});
|
||||
@ -1077,11 +1077,11 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".git2."0.13.0" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".git2."0.13.1" = overridableMkRustCrate (profileName: rec {
|
||||
name = "git2";
|
||||
version = "0.13.0";
|
||||
version = "0.13.1";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "b7da16ceafe24cedd9ba02c4463a2b506b6493baf4317c79c5acb553134a3c15"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "ef222034f2069cfc5af01ce423574d3d9a3925bd4052912a14e5bcfd7ca9e47a"; };
|
||||
features = builtins.concatLists [
|
||||
[ "default" ]
|
||||
[ "https" ]
|
||||
@ -1093,7 +1093,7 @@ in
|
||||
dependencies = {
|
||||
bitflags = rustPackages."registry+https://github.com/rust-lang/crates.io-index".bitflags."1.2.1" { inherit profileName; };
|
||||
libc = rustPackages."registry+https://github.com/rust-lang/crates.io-index".libc."0.2.66" { inherit profileName; };
|
||||
libgit2_sys = rustPackages."registry+https://github.com/rust-lang/crates.io-index".libgit2-sys."0.12.0+0.99.0" { inherit profileName; };
|
||||
libgit2_sys = rustPackages."registry+https://github.com/rust-lang/crates.io-index".libgit2-sys."0.12.2+1.0.0" { inherit profileName; };
|
||||
log = rustPackages."registry+https://github.com/rust-lang/crates.io-index".log."0.4.8" { inherit profileName; };
|
||||
${ if hostPlatform.isUnix && !(hostPlatform.parsed.kernel.name == "darwin") then "openssl_probe" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".openssl-probe."0.1.2" { inherit profileName; };
|
||||
${ if hostPlatform.isUnix && !(hostPlatform.parsed.kernel.name == "darwin") then "openssl_sys" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".openssl-sys."0.9.54" { inherit profileName; };
|
||||
@ -1101,11 +1101,11 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".h2."0.2.1" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".h2."0.2.4" = overridableMkRustCrate (profileName: rec {
|
||||
name = "h2";
|
||||
version = "0.2.1";
|
||||
version = "0.2.4";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "b9433d71e471c1736fd5a61b671fc0b148d7a2992f666c958d03cd8feb3b88d1"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "377038bf3c89d18d6ca1431e7a5027194fbd724ca10592b9487ede5e8e144f42"; };
|
||||
dependencies = {
|
||||
bytes = rustPackages."registry+https://github.com/rust-lang/crates.io-index".bytes."0.5.4" { inherit profileName; };
|
||||
fnv = rustPackages."registry+https://github.com/rust-lang/crates.io-index".fnv."1.0.6" { inherit profileName; };
|
||||
@ -1117,7 +1117,7 @@ in
|
||||
log = rustPackages."registry+https://github.com/rust-lang/crates.io-index".log."0.4.8" { inherit profileName; };
|
||||
slab = rustPackages."registry+https://github.com/rust-lang/crates.io-index".slab."0.4.2" { inherit profileName; };
|
||||
tokio = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio."0.2.11" { inherit profileName; };
|
||||
tokio_util = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio-util."0.2.0" { inherit profileName; };
|
||||
tokio_util = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio-util."0.3.1" { inherit profileName; };
|
||||
};
|
||||
});
|
||||
|
||||
@ -1144,9 +1144,9 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"unknown".hoc."0.11.5" = overridableMkRustCrate (profileName: rec {
|
||||
"unknown".hoc."0.11.8" = overridableMkRustCrate (profileName: rec {
|
||||
name = "hoc";
|
||||
version = "0.11.5";
|
||||
version = "0.11.8";
|
||||
registry = "unknown";
|
||||
src = fetchCrateLocal ./.;
|
||||
dependencies = {
|
||||
@ -1155,16 +1155,16 @@ in
|
||||
badge = rustPackages."registry+https://github.com/rust-lang/crates.io-index".badge."0.2.0" { inherit profileName; };
|
||||
bytes = rustPackages."registry+https://github.com/rust-lang/crates.io-index".bytes."0.5.4" { inherit profileName; };
|
||||
futures = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures."0.3.4" { inherit profileName; };
|
||||
git2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".git2."0.13.0" { inherit profileName; };
|
||||
git2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".git2."0.13.1" { inherit profileName; };
|
||||
lazy_static = rustPackages."registry+https://github.com/rust-lang/crates.io-index".lazy_static."1.4.0" { inherit profileName; };
|
||||
log = rustPackages."registry+https://github.com/rust-lang/crates.io-index".log."0.4.8" { inherit profileName; };
|
||||
log4rs = rustPackages."registry+https://github.com/rust-lang/crates.io-index".log4rs."0.11.0" { inherit profileName; };
|
||||
number_prefix = rustPackages."registry+https://github.com/rust-lang/crates.io-index".number_prefix."0.3.0" { inherit profileName; };
|
||||
openssl_probe = rustPackages."registry+https://github.com/rust-lang/crates.io-index".openssl-probe."0.1.2" { inherit profileName; };
|
||||
reqwest = rustPackages."registry+https://github.com/rust-lang/crates.io-index".reqwest."0.10.3" { inherit profileName; };
|
||||
reqwest = rustPackages."registry+https://github.com/rust-lang/crates.io-index".reqwest."0.10.4" { inherit profileName; };
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_derive = buildRustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_derive."1.0.105" { profileName = "__noProfile"; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
structopt = rustPackages."registry+https://github.com/rust-lang/crates.io-index".structopt."0.3.12" { inherit profileName; };
|
||||
};
|
||||
buildDependencies = {
|
||||
@ -1228,11 +1228,11 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.2" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.4" = overridableMkRustCrate (profileName: rec {
|
||||
name = "hyper";
|
||||
version = "0.13.2";
|
||||
version = "0.13.4";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "fa1c527bbc634be72aa7ba31e4e4def9bbb020f5416916279b7c705cd838893e"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "ed6081100e960d9d74734659ffc9cc91daf1c0fc7aceb8eaa94ee1a3f5046f2e"; };
|
||||
features = builtins.concatLists [
|
||||
[ "net2" ]
|
||||
[ "tcp" ]
|
||||
@ -1242,7 +1242,7 @@ in
|
||||
futures_channel = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-channel."0.3.4" { inherit profileName; };
|
||||
futures_core = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-core."0.3.4" { inherit profileName; };
|
||||
futures_util = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-util."0.3.4" { inherit profileName; };
|
||||
h2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".h2."0.2.1" { inherit profileName; };
|
||||
h2 = rustPackages."registry+https://github.com/rust-lang/crates.io-index".h2."0.2.4" { inherit profileName; };
|
||||
http = rustPackages."registry+https://github.com/rust-lang/crates.io-index".http."0.2.0" { inherit profileName; };
|
||||
http_body = rustPackages."registry+https://github.com/rust-lang/crates.io-index".http-body."0.3.1" { inherit profileName; };
|
||||
httparse = rustPackages."registry+https://github.com/rust-lang/crates.io-index".httparse."1.3.4" { inherit profileName; };
|
||||
@ -1264,7 +1264,7 @@ in
|
||||
src = fetchCratesIo { inherit name version; sha256 = "3adcd308402b9553630734e9c36b77a7e48b3821251ca2493e8cd596763aafaa"; };
|
||||
dependencies = {
|
||||
bytes = rustPackages."registry+https://github.com/rust-lang/crates.io-index".bytes."0.5.4" { inherit profileName; };
|
||||
hyper = rustPackages."registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.2" { inherit profileName; };
|
||||
hyper = rustPackages."registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.4" { inherit profileName; };
|
||||
native_tls = rustPackages."registry+https://github.com/rust-lang/crates.io-index".native-tls."0.2.3" { inherit profileName; };
|
||||
tokio = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio."0.2.11" { inherit profileName; };
|
||||
tokio_tls = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio-tls."0.3.0" { inherit profileName; };
|
||||
@ -1423,11 +1423,11 @@ in
|
||||
];
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".libgit2-sys."0.12.0+0.99.0" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".libgit2-sys."0.12.2+1.0.0" = overridableMkRustCrate (profileName: rec {
|
||||
name = "libgit2-sys";
|
||||
version = "0.12.0+0.99.0";
|
||||
version = "0.12.2+1.0.0";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "05dff41ac39e7b653f5f1550886cf00ba52f8e7f57210b633cdeedb3de5b236c"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "a12c878ccc1a49ff71e264233a66d2114cdcc7fdc44c0ebe2b54075240831238"; };
|
||||
features = builtins.concatLists [
|
||||
[ "https" ]
|
||||
[ "libssh2-sys" ]
|
||||
@ -1570,7 +1570,7 @@ in
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_value = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde-value."0.6.0" { inherit profileName; };
|
||||
serde_derive = buildRustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_derive."1.0.105" { profileName = "__noProfile"; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
serde_yaml = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_yaml."0.8.11" { inherit profileName; };
|
||||
thread_id = rustPackages."registry+https://github.com/rust-lang/crates.io-index".thread-id."3.3.0" { inherit profileName; };
|
||||
typemap = rustPackages."registry+https://github.com/rust-lang/crates.io-index".typemap."0.3.3" { inherit profileName; };
|
||||
@ -2206,11 +2206,11 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".reqwest."0.10.3" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".reqwest."0.10.4" = overridableMkRustCrate (profileName: rec {
|
||||
name = "reqwest";
|
||||
version = "0.10.3";
|
||||
version = "0.10.4";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "a9f62f24514117d09a8fc74b803d3d65faa27cea1c7378fb12b0d002913f3831"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "02b81e49ddec5109a9dcfc5f2a317ff53377c915e9ae9d4f2fb50914b85614e2"; };
|
||||
features = builtins.concatLists [
|
||||
[ "__tls" ]
|
||||
[ "default" ]
|
||||
@ -2227,7 +2227,7 @@ in
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "futures_util" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-util."0.3.4" { inherit profileName; };
|
||||
http = rustPackages."registry+https://github.com/rust-lang/crates.io-index".http."0.2.0" { inherit profileName; };
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "http_body" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".http-body."0.3.1" { inherit profileName; };
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "hyper" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.2" { inherit profileName; };
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "hyper" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".hyper."0.13.4" { inherit profileName; };
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "hyper_tls" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".hyper-tls."0.4.1" { inherit profileName; };
|
||||
${ if hostPlatform.parsed.cpu.name == "wasm32" then "js_sys" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".js-sys."0.3.35" { inherit profileName; };
|
||||
${ if !(hostPlatform.parsed.cpu.name == "wasm32") then "lazy_static" else null } = rustPackages."registry+https://github.com/rust-lang/crates.io-index".lazy_static."1.4.0" { inherit profileName; };
|
||||
@ -2441,11 +2441,11 @@ in
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" = overridableMkRustCrate (profileName: rec {
|
||||
"registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" = overridableMkRustCrate (profileName: rec {
|
||||
name = "serde_json";
|
||||
version = "1.0.48";
|
||||
version = "1.0.50";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "9371ade75d4c2d6cb154141b9752cf3781ec9c05e0e5cf35060e1e70ee7b9c25"; };
|
||||
src = fetchCratesIo { inherit name version; sha256 = "78a7a12c167809363ec3bd7329fc0a3369056996de43c4b37ef3cd54a6ce4867"; };
|
||||
features = builtins.concatLists [
|
||||
[ "default" ]
|
||||
[ "std" ]
|
||||
@ -2789,6 +2789,24 @@ in
|
||||
version = "0.2.0";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "571da51182ec208780505a32528fc5512a8fe1443ab960b3f2f3ef093cd16930"; };
|
||||
features = builtins.concatLists [
|
||||
[ "codec" ]
|
||||
];
|
||||
dependencies = {
|
||||
bytes = rustPackages."registry+https://github.com/rust-lang/crates.io-index".bytes."0.5.4" { inherit profileName; };
|
||||
futures_core = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-core."0.3.4" { inherit profileName; };
|
||||
futures_sink = rustPackages."registry+https://github.com/rust-lang/crates.io-index".futures-sink."0.3.4" { inherit profileName; };
|
||||
log = rustPackages."registry+https://github.com/rust-lang/crates.io-index".log."0.4.8" { inherit profileName; };
|
||||
pin_project_lite = rustPackages."registry+https://github.com/rust-lang/crates.io-index".pin-project-lite."0.1.4" { inherit profileName; };
|
||||
tokio = rustPackages."registry+https://github.com/rust-lang/crates.io-index".tokio."0.2.11" { inherit profileName; };
|
||||
};
|
||||
});
|
||||
|
||||
"registry+https://github.com/rust-lang/crates.io-index".tokio-util."0.3.1" = overridableMkRustCrate (profileName: rec {
|
||||
name = "tokio-util";
|
||||
version = "0.3.1";
|
||||
registry = "registry+https://github.com/rust-lang/crates.io-index";
|
||||
src = fetchCratesIo { inherit name version; sha256 = "be8242891f2b6cbef26a2d7e8605133c2c554cd35b3e4948ea892d6d68436499"; };
|
||||
features = builtins.concatLists [
|
||||
[ "codec" ]
|
||||
[ "default" ]
|
||||
@ -3064,7 +3082,7 @@ in
|
||||
dependencies = {
|
||||
cfg_if = rustPackages."registry+https://github.com/rust-lang/crates.io-index".cfg-if."0.1.10" { inherit profileName; };
|
||||
serde = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde."1.0.105" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.48" { inherit profileName; };
|
||||
serde_json = rustPackages."registry+https://github.com/rust-lang/crates.io-index".serde_json."1.0.50" { inherit profileName; };
|
||||
wasm_bindgen_macro = buildRustPackages."registry+https://github.com/rust-lang/crates.io-index".wasm-bindgen-macro."0.2.58" { profileName = "__noProfile"; };
|
||||
};
|
||||
});
|
||||
|
25
Cargo.toml
25
Cargo.toml
@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "hoc"
|
||||
version = "0.11.6"
|
||||
version = "0.12.0"
|
||||
authors = ["Valentin Brandl <vbrandl@riseup.net>"]
|
||||
edition = "2018"
|
||||
build = "build.rs"
|
||||
@ -9,20 +9,23 @@ build = "build.rs"
|
||||
actix-web = "2.0.0"
|
||||
badge = "0.2.0"
|
||||
bytes = "0.5.4"
|
||||
futures = "0.3.1"
|
||||
git2 = "0.13.0"
|
||||
futures = "0.3.5"
|
||||
git2 = "0.13.5"
|
||||
lazy_static = "1.4.0"
|
||||
log = "0.4.8"
|
||||
log4rs = "0.11.0"
|
||||
number_prefix = "0.3.0"
|
||||
log4rs = "0.12.0"
|
||||
number_prefix = "0.4.0"
|
||||
openssl-probe = "0.1.2"
|
||||
reqwest = "0.10.3"
|
||||
serde = "1.0.105"
|
||||
reqwest = "0.10.4"
|
||||
serde = "1.0.110"
|
||||
serde_derive = "1.0.103"
|
||||
serde_json = "1.0.48"
|
||||
structopt = "0.3.12"
|
||||
actix-rt = "1.0.0"
|
||||
serde_json = "1.0.53"
|
||||
structopt = "0.3.14"
|
||||
actix-rt = "1.1.1"
|
||||
|
||||
[build-dependencies]
|
||||
ructe = "0.9.2"
|
||||
ructe = "0.11.4"
|
||||
vergen = "3.1.0"
|
||||
|
||||
[dev-dependencies]
|
||||
tempfile = "3.1.0"
|
||||
|
11
default.nix
11
default.nix
@ -39,13 +39,18 @@ rec {
|
||||
dockerImage =
|
||||
pkgs.dockerTools.buildImage {
|
||||
name = "vbrandl/hits-of-code";
|
||||
tag = "1";
|
||||
tag = package.version;
|
||||
|
||||
contents = [ package ];
|
||||
contents =
|
||||
[
|
||||
package
|
||||
pkgs.cacert
|
||||
pkgs.gitMinimal
|
||||
];
|
||||
|
||||
config = {
|
||||
Cmd = [ "/bin/hoc" ];
|
||||
WorkingDir = "/";
|
||||
WorkingDir = "/home/hoc";
|
||||
};
|
||||
};
|
||||
}
|
||||
|
@ -5,6 +5,7 @@ pub(crate) fn count_repositories<P>(repo_path: P) -> Result<usize>
|
||||
where
|
||||
P: AsRef<Path>,
|
||||
{
|
||||
std::fs::create_dir_all(&repo_path)?;
|
||||
Ok(read_dir(repo_path)?
|
||||
.filter_map(StdResult::ok)
|
||||
.filter(|entry| entry.file_type().map(|ft| ft.is_dir()).unwrap_or(false))
|
||||
|
100
src/main.rs
100
src/main.rs
@ -17,6 +17,9 @@ mod service;
|
||||
mod statics;
|
||||
mod template;
|
||||
|
||||
#[cfg(test)]
|
||||
mod tests;
|
||||
|
||||
use crate::{
|
||||
cache::CacheState,
|
||||
error::{Error, Result},
|
||||
@ -25,16 +28,16 @@ use crate::{
|
||||
template::RepoInfo,
|
||||
};
|
||||
use actix_web::{
|
||||
http::header::{CacheControl, CacheDirective, Expires},
|
||||
middleware, web, App, HttpResponse, HttpServer,
|
||||
http::header::{CacheControl, CacheDirective, Expires, LOCATION},
|
||||
middleware, web, App, HttpResponse, HttpServer, Responder,
|
||||
};
|
||||
use badge::{Badge, BadgeOptions};
|
||||
use futures::future::Future;
|
||||
use git2::Repository;
|
||||
use number_prefix::{NumberPrefix, Prefixed, Standalone};
|
||||
use number_prefix::NumberPrefix;
|
||||
use std::{
|
||||
borrow::Cow,
|
||||
fs::create_dir_all,
|
||||
io,
|
||||
path::Path,
|
||||
process::Command,
|
||||
sync::atomic::Ordering,
|
||||
@ -51,7 +54,8 @@ struct GeneratorForm<'a> {
|
||||
repo: Cow<'a, str>,
|
||||
}
|
||||
|
||||
struct State {
|
||||
#[derive(Debug)]
|
||||
pub(crate) struct State {
|
||||
repos: String,
|
||||
cache: String,
|
||||
}
|
||||
@ -145,9 +149,6 @@ fn hoc(repo: &str, repo_dir: &str, cache_dir: &str) -> Result<(u64, String, u64)
|
||||
async fn remote_exists(url: &str) -> Result<bool> {
|
||||
let resp = CLIENT.head(url).send().await?;
|
||||
Ok(resp.status() == reqwest::StatusCode::OK)
|
||||
|
||||
// .map(|resp| resp.status() == reqwest::StatusCode::OK)
|
||||
// .from_err()
|
||||
}
|
||||
|
||||
enum HocResult {
|
||||
@ -163,6 +164,45 @@ enum HocResult {
|
||||
NotFound,
|
||||
}
|
||||
|
||||
async fn delete_repo_and_cache<T>(
|
||||
state: web::Data<Arc<State>>,
|
||||
data: web::Path<(String, String)>,
|
||||
) -> Result<impl Responder>
|
||||
where
|
||||
T: Service,
|
||||
{
|
||||
let repo = format!(
|
||||
"{}/{}/{}",
|
||||
T::domain(),
|
||||
data.0.to_lowercase(),
|
||||
data.1.to_lowercase()
|
||||
);
|
||||
info!("Deleting cache and repository for {}", repo);
|
||||
let cache_dir = dbg!(format!("{}/{}.json", &state.cache, repo));
|
||||
let repo_dir = dbg!(format!("{}/{}", &state.repos, repo));
|
||||
std::fs::remove_file(&cache_dir).or_else(|e| {
|
||||
if e.kind() == io::ErrorKind::NotFound {
|
||||
Ok(())
|
||||
} else {
|
||||
Err(e)
|
||||
}
|
||||
})?;
|
||||
std::fs::remove_dir_all(&repo_dir).or_else(|e| {
|
||||
if e.kind() == io::ErrorKind::NotFound {
|
||||
Ok(())
|
||||
} else {
|
||||
Err(e)
|
||||
}
|
||||
})?;
|
||||
REPO_COUNT.fetch_sub(1, Ordering::Relaxed);
|
||||
Ok(HttpResponse::TemporaryRedirect()
|
||||
.header(
|
||||
LOCATION,
|
||||
format!("/view/{}/{}/{}", T::url_path(), data.0, data.1),
|
||||
)
|
||||
.finish())
|
||||
}
|
||||
|
||||
async fn handle_hoc_request<T, F>(
|
||||
state: web::Data<Arc<State>>,
|
||||
data: web::Path<(String, String)>,
|
||||
@ -173,9 +213,11 @@ where
|
||||
F: Fn(HocResult) -> Result<HttpResponse>,
|
||||
{
|
||||
let repo = format!("{}/{}", data.0.to_lowercase(), data.1.to_lowercase());
|
||||
let service_path = format!("{}/{}", T::domain(), repo);
|
||||
let path = format!("{}/{}", state.repos, service_path);
|
||||
let url = format!("https://{}", service_path);
|
||||
let service_path = format!("{}/{}", T::url_path(), repo);
|
||||
let service_url = format!("{}/{}", T::domain(), repo);
|
||||
let path = format!("{}/{}", state.repos, service_url);
|
||||
let url = format!("https://{}", service_url);
|
||||
error!("{}", url);
|
||||
let remote_exists = remote_exists(&url).await?;
|
||||
let file = Path::new(&path);
|
||||
if !file.exists() {
|
||||
@ -191,10 +233,10 @@ where
|
||||
REPO_COUNT.fetch_add(1, Ordering::Relaxed);
|
||||
}
|
||||
pull(&path)?;
|
||||
let (hoc, head, commits) = hoc(&service_path, &state.repos, &state.cache)?;
|
||||
let (hoc, head, commits) = hoc(&service_url, &state.repos, &state.cache)?;
|
||||
let hoc_pretty = match NumberPrefix::decimal(hoc as f64) {
|
||||
Standalone(hoc) => hoc.to_string(),
|
||||
Prefixed(prefix, hoc) => format!("{:.1}{}", hoc, prefix),
|
||||
NumberPrefix::Standalone(hoc) => hoc.to_string(),
|
||||
NumberPrefix::Prefixed(prefix, hoc) => format!("{:.1}{}", hoc, prefix),
|
||||
};
|
||||
let res = HocResult::Hoc {
|
||||
hoc,
|
||||
@ -208,10 +250,10 @@ where
|
||||
mapper(res)
|
||||
}
|
||||
|
||||
fn json_hoc<T: Service>(
|
||||
pub(crate) async fn json_hoc<T: Service>(
|
||||
state: web::Data<Arc<State>>,
|
||||
data: web::Path<(String, String)>,
|
||||
) -> impl Future<Output = Result<HttpResponse>> {
|
||||
) -> Result<HttpResponse> {
|
||||
let mapper = |r| match r {
|
||||
HocResult::NotFound => p404(),
|
||||
HocResult::Hoc {
|
||||
@ -222,13 +264,13 @@ fn json_hoc<T: Service>(
|
||||
commits,
|
||||
})),
|
||||
};
|
||||
handle_hoc_request::<T, _>(state, data, mapper)
|
||||
handle_hoc_request::<T, _>(state, data, mapper).await
|
||||
}
|
||||
|
||||
fn calculate_hoc<T: Service>(
|
||||
pub(crate) async fn calculate_hoc<T: Service>(
|
||||
state: web::Data<Arc<State>>,
|
||||
data: web::Path<(String, String)>,
|
||||
) -> impl Future<Output = Result<HttpResponse>> {
|
||||
) -> Result<HttpResponse> {
|
||||
let mapper = move |r| match r {
|
||||
HocResult::NotFound => p404(),
|
||||
HocResult::Hoc { hoc_pretty, .. } => {
|
||||
@ -254,13 +296,13 @@ fn calculate_hoc<T: Service>(
|
||||
.body(body))
|
||||
}
|
||||
};
|
||||
handle_hoc_request::<T, _>(state, data, mapper)
|
||||
handle_hoc_request::<T, _>(state, data, mapper).await
|
||||
}
|
||||
|
||||
fn overview<T: Service>(
|
||||
async fn overview<T: Service>(
|
||||
state: web::Data<Arc<State>>,
|
||||
data: web::Path<(String, String)>,
|
||||
) -> impl Future<Output = Result<HttpResponse>> {
|
||||
) -> Result<HttpResponse> {
|
||||
let mapper = |r| match r {
|
||||
HocResult::NotFound => p404(),
|
||||
HocResult::Hoc {
|
||||
@ -293,7 +335,7 @@ fn overview<T: Service>(
|
||||
Ok(HttpResponse::Ok().content_type("text/html").body(buf))
|
||||
}
|
||||
};
|
||||
handle_hoc_request::<T, _>(state, data, mapper)
|
||||
handle_hoc_request::<T, _>(state, data, mapper).await
|
||||
}
|
||||
|
||||
#[get("/")]
|
||||
@ -363,6 +405,18 @@ async fn start_server() -> std::io::Result<()> {
|
||||
.service(web::resource("/github/{user}/{repo}").to(calculate_hoc::<GitHub>))
|
||||
.service(web::resource("/gitlab/{user}/{repo}").to(calculate_hoc::<Gitlab>))
|
||||
.service(web::resource("/bitbucket/{user}/{repo}").to(calculate_hoc::<Bitbucket>))
|
||||
.service(
|
||||
web::resource("/github/{user}/{repo}/delete")
|
||||
.route(web::post().to(delete_repo_and_cache::<GitHub>)),
|
||||
)
|
||||
.service(
|
||||
web::resource("/gitlab/{user}/{repo}/delete")
|
||||
.route(web::post().to(delete_repo_and_cache::<Gitlab>)),
|
||||
)
|
||||
.service(
|
||||
web::resource("/bitbucket/{user}/{repo}/delete")
|
||||
.route(web::post().to(delete_repo_and_cache::<Bitbucket>)),
|
||||
)
|
||||
.service(web::resource("/github/{user}/{repo}/json").to(json_hoc::<GitHub>))
|
||||
.service(web::resource("/gitlab/{user}/{repo}/json").to(json_hoc::<Gitlab>))
|
||||
.service(web::resource("/bitbucket/{user}/{repo}/json").to(json_hoc::<Bitbucket>))
|
||||
|
66
src/tests.rs
Normal file
66
src/tests.rs
Normal file
@ -0,0 +1,66 @@
|
||||
use crate::{
|
||||
calculate_hoc, index, json_hoc,
|
||||
service::{Bitbucket, GitHub, Gitlab, Service},
|
||||
State,
|
||||
};
|
||||
|
||||
use actix_web::{http, test, web, App};
|
||||
use tempfile::tempdir;
|
||||
|
||||
macro_rules! test_app {
|
||||
($path: expr) => {
|
||||
test::init_service(App::new().service($path)).await
|
||||
};
|
||||
($state: expr, $path: expr) => {
|
||||
test::init_service(App::new().data($state).service($path)).await
|
||||
};
|
||||
}
|
||||
|
||||
macro_rules! test_service {
|
||||
($name: ident, $path: tt, $what: ident) => {
|
||||
async fn $name<T: 'static + Service>(req_path: &str) {
|
||||
let repo_dir = dbg!(tempdir().unwrap());
|
||||
let cache_dir = dbg!(tempdir().unwrap());
|
||||
let repos = format!("{}/", repo_dir.path().display());
|
||||
let cache = format!("{}/", cache_dir.path().display());
|
||||
let state = dbg!(State { repos, cache });
|
||||
|
||||
let mut app = test_app!(state, web::resource($path).to($what::<T>));
|
||||
|
||||
let req = dbg!(test::TestRequest::with_uri(req_path).to_request());
|
||||
let resp = dbg!(test::call_service(&mut app, req).await);
|
||||
|
||||
assert_eq!(resp.status(), http::StatusCode::OK);
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
#[actix_rt::test]
|
||||
async fn test_index() {
|
||||
let mut app = test::init_service(App::new().service(index)).await;
|
||||
|
||||
let req = dbg!(test::TestRequest::with_uri("/").to_request());
|
||||
let resp = dbg!(test::call_service(&mut app, req).await);
|
||||
|
||||
assert_eq!(resp.status(), http::StatusCode::OK);
|
||||
}
|
||||
|
||||
// TODO: fix this test
|
||||
// #[actix_rt::test]
|
||||
async fn test_json() {
|
||||
test_service!(test_json_service, "/service/{user}/{repo}/json", json_hoc);
|
||||
|
||||
test_json_service::<Gitlab>("/service/vbrandl/hoc/json").await;
|
||||
test_json_service::<GitHub>("/service/vbrandl/hoc/json").await;
|
||||
test_json_service::<Bitbucket>("/service/vbrandl/hoc/json").await;
|
||||
}
|
||||
|
||||
// TODO: fix this test
|
||||
// #[actix_rt::test]
|
||||
async fn test_badge() {
|
||||
test_service!(test_badge_service, "/service/{user}/{repo}", calculate_hoc);
|
||||
|
||||
test_badge_service::<Gitlab>("/service/vbrandl/hoc").await;
|
||||
test_badge_service::<GitHub>("/service/vbrandl/hoc").await;
|
||||
test_badge_service::<Bitbucket>("/service/vbrandl/hoc").await;
|
||||
}
|
@ -20,4 +20,9 @@ To include the badge in your readme, use the following markdown:
|
||||
<pre>
|
||||
[](https://@repo_info.domain/view/@repo_info.path)
|
||||
</pre>
|
||||
|
||||
|
||||
<form method="post" action="/@repo_info.path/delete">
|
||||
<button type="submit">Rebuild Cache</button>
|
||||
</form>
|
||||
}, version_info, repo_count)
|
||||
|
Reference in New Issue
Block a user