Compare commits

..

15 Commits

Author SHA1 Message Date
Cadey Ratio c5ff939007 blog/we-have-go-2: fix indent
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-13 00:51:42 +00:00
Cadey Ratio c55ef48ba3 blog/we-have-go-2: write generics section
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-13 00:51:42 +00:00
Cadey Ratio bdc85b1536 blog/we-have-go-2: more into generics 2022-05-13 00:51:42 +00:00
Cadey Ratio b1264c8b69 blog/we-have-go-2: more changes from the park 2022-05-13 00:51:42 +00:00
Cadey Ratio 1d0066eeda blog: we already have go 2
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-13 00:51:42 +00:00
Cadey Ratio 43a542e192 stickybox
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-12 21:53:48 +00:00
Cadey Ratio 7e92f3c7a9 adaptive class
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-12 21:43:40 +00:00
Cadey Ratio 737b4700a0 put ads at the end
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-12 21:25:56 +00:00
Cadey Ratio 22ab51b29c oops lol
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-12 21:24:53 +00:00
Cadey Ratio b312b9931d add ethicalads
Signed-off-by: Xe Iaso <me@christine.website>
2022-05-12 21:22:50 +00:00
dependabot[bot] e057c81325
build(deps): bump axum-extra from 0.3.0 to 0.3.1 (#471)
Bumps [axum-extra](https://github.com/tokio-rs/axum) from 0.3.0 to 0.3.1.
- [Release notes](https://github.com/tokio-rs/axum/releases)
- [Changelog](https://github.com/tokio-rs/axum/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/axum/compare/axum-extra-v0.3.0...axum-extra-v0.3.1)

---
updated-dependencies:
- dependency-name: axum-extra
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-11 22:06:26 -04:00
dependabot[bot] fd6d806365
build(deps): bump axum from 0.5.4 to 0.5.5 (#470)
Bumps [axum](https://github.com/tokio-rs/axum) from 0.5.4 to 0.5.5.
- [Release notes](https://github.com/tokio-rs/axum/releases)
- [Changelog](https://github.com/tokio-rs/axum/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/axum/compare/axum-v0.5.4...axum-v0.5.5)

---
updated-dependencies:
- dependency-name: axum
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-11 22:06:22 -04:00
dependabot[bot] e351243126
build(deps): bump axum-macros from 0.2.0 to 0.2.1 (#469)
Bumps [axum-macros](https://github.com/tokio-rs/axum) from 0.2.0 to 0.2.1.
- [Release notes](https://github.com/tokio-rs/axum/releases)
- [Changelog](https://github.com/tokio-rs/axum/blob/main/CHANGELOG.md)
- [Commits](https://github.com/tokio-rs/axum/compare/axum-macros-v0.2.0...axum-macros-v0.2.1)

---
updated-dependencies:
- dependency-name: axum-macros
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-11 22:06:16 -04:00
dependabot[bot] eee6502aa1
build(deps): bump tower-http from 0.3.2 to 0.3.3 (#468)
Bumps [tower-http](https://github.com/tower-rs/tower-http) from 0.3.2 to 0.3.3.
- [Release notes](https://github.com/tower-rs/tower-http/releases)
- [Commits](https://github.com/tower-rs/tower-http/compare/tower-http-0.3.2...tower-http-0.3.3)

---
updated-dependencies:
- dependency-name: tower-http
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>

Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2022-05-09 07:33:20 -04:00
Charlie Groves c07ac3b6c0
Fix examples to work with Nix >= 2.7 (#467) 2022-05-08 22:18:17 -04:00
4 changed files with 50 additions and 21 deletions

32
Cargo.lock generated
View File

@ -141,9 +141,9 @@ checksum = "d468802bab17cbc0cc575e9b053f41e72aa36bfa6b7f55e3529ffa43161b97fa"
[[package]]
name = "axum"
version = "0.5.4"
version = "0.5.5"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "f4af7447fc1214c1f3a1ace861d0216a6c8bb13965b64bbad9650f375b67689a"
checksum = "00f1e8a972137fad81e2a1a60b86ff17ce0338f8017264e45a9723d0083c39a1"
dependencies = [
"async-trait",
"axum-core",
@ -172,9 +172,9 @@ dependencies = [
[[package]]
name = "axum-core"
version = "0.2.3"
version = "0.2.4"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "3bdc19781b16e32f8a7200368a336fa4509d4b72ef15dd4e41df5290855ee1e6"
checksum = "da31c0ed7b4690e2c78fe4b880d21cd7db04a346ebc658b4270251b695437f17"
dependencies = [
"async-trait",
"bytes",
@ -186,9 +186,9 @@ dependencies = [
[[package]]
name = "axum-extra"
version = "0.3.0"
version = "0.3.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "a00a7085c512df12d4e07a862b23a3b3bfe5326ecfc4185b49fb15c8850ba406"
checksum = "f77e63453d67cf14576bad0f395ad1541f0b92949a6a53b548f40b77158fc095"
dependencies = [
"axum",
"bytes",
@ -203,9 +203,9 @@ dependencies = [
[[package]]
name = "axum-macros"
version = "0.2.0"
version = "0.2.1"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "63bcb0d395bc5dd286e61aada9fc48201eb70e232f006f9d6c330c9db2f256f5"
checksum = "3dc20c9d065f7232b92740f99001addacef62697ed3a030369ef193140d7621c"
dependencies = [
"heck",
"proc-macro2",
@ -2635,9 +2635,9 @@ dependencies = [
[[package]]
name = "tower-http"
version = "0.3.2"
version = "0.3.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "e980386f06883cf4d0578d6c9178c81f68b45d77d00f2c2c1bc034b3439c2c56"
checksum = "7d342c6d58709c0a6d48d48dabbb62d4ef955cf5f0f3bbfd845838e7ae88dbae"
dependencies = [
"async-compression",
"base64",
@ -2660,6 +2660,7 @@ dependencies = [
"tower-layer",
"tower-service",
"tracing",
"uuid 1.0.0",
]
[[package]]
@ -2857,6 +2858,15 @@ dependencies = [
"serde",
]
[[package]]
name = "uuid"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "8cfcd319456c4d6ea10087ed423473267e1a071f3bc0aa89f80d60997843c6f0"
dependencies = [
"getrandom 0.2.5",
]
[[package]]
name = "valuable"
version = "0.1.0"
@ -3137,7 +3147,7 @@ dependencies = [
"tracing-futures",
"tracing-subscriber",
"url",
"uuid",
"uuid 0.8.2",
"xml-rs",
]

View File

@ -207,12 +207,12 @@ Let's take a closer look at the higher level things in the flake:
your `flake.nix`. Ditto with "flake input" referring to the `inputs` attribute
of your `flake.nix`.](conversation://Cadey/enby)
When you ran `nix build` earlier, it defaulted to building the package in
`defaultPackage`. You can also build the `go-hello` package by running this
When you ran `nix build` earlier, it defaulted to building the `default` entry
in `packages`. You can also build the `default` package by running this
command:
```console
$ nix build .#go-hello
$ nix build .#default
```
And if you want to build the copy I made for this post:
@ -234,11 +234,13 @@ simplify that above `nix build` and `./result/bin/go-hello` cycle into a single
`go-hello` to be the default app:
```nix
# below defaultPackage
# below packages
defaultApp = forAllSystems (system: {
type = "app";
program = "${self.packages.${system}.go-hello}/bin/go-hello";
apps = forAllSystems (system: {
default = {
type = "app";
program = "${self.packages.${system}.default}/bin/go-hello";
};
});
```
@ -281,8 +283,10 @@ can add it to your `flake.nix` using this:
devShell = forAllSystems (system:
let pkgs = nixpkgsFor.${system};
in pkgs.mkShell {
buildInputs = with pkgs; [ go gopls goimports go-tools ];
in {
default = pkgs.mkShell {
buildInputs = with pkgs; [ go gopls gotools go-tools ];
};
});
```

View File

@ -68,12 +68,16 @@
<div class="warning">
@:mara("hacker", "Mara", Html(format!(r#"Hey, this post is set to go live to the public on {}. Right now you are reading a pre-publication version of this post. Please do not share this on social media. This post will automatically go live for everyone on the intended publication date. If you want access to these posts, please join the <a href="https://patreon.com/cadey">Patreon</a>. It helps me afford the copyeditor that I contract for the technical content I write."#, post.detri())))
</div>
} else {
<script async src="https://media.ethicalads.io/media/client/ethicalads.min.js"></script>
}
<small>A @post.read_time_estimate_minutes minute read.</small>
@body
<div class="adaptive" data-ea-publisher="christinewebsite" data-ea-type="image" data-ea-style="stickybox"></div>
<hr />
@if post.front_matter.vod.is_some() {

View File

@ -1,5 +1,6 @@
@use super::{header_html, footer_html};
@use super::{header_html, footer_html, mara};
@use crate::post::Post;
@use chrono::prelude::*;
@(post: Post, body: impl ToHtml)
@ -47,10 +48,20 @@
@}
</script>
@if Utc::today().num_days_from_ce() < post.date.num_days_from_ce() {
<div class="warning">
@:mara("hacker", "Mara", Html(format!(r#"Hey, this post is set to go live to the public on {}. Right now you are reading a pre-publication version of this post. Please do not share this on social media. This post will automatically go live for everyone on the intended publication date. If you want access to these posts, please join the <a href="https://patreon.com/cadey">Patreon</a>. It helps me afford the copyeditor that I contract for the technical content I write."#, post.detri())))
</div>
} else {
<script async src="https://media.ethicalads.io/media/client/ethicalads.min.js"></script>
}
@body
<a href="@post.front_matter.slides_link.as_ref().unwrap()">Link to the slides</a>
<div data-ea-publisher="christinewebsite" data-ea-type="text"></div>
<hr />
<!-- The button that should be clicked. -->