summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--content/posts/2017/2017-11-16-perl6-setting-up-a-raspberry-perl.md4
-rw-r--r--content/posts/2017/2017-12-21-funding-yourself-as-free-software-developer.md24
-rw-r--r--content/posts/2018/2018-03-20-perl6-introduction-to-application-programming.md24
-rw-r--r--content/posts/2018/2018-05-07-sparrowdo-getting-started.md16
-rw-r--r--content/posts/2018/2018-08-15-the-perl-conference-in-glasgow.md12
-rw-r--r--content/posts/2018/2018-09-04-setting-up-pgp-with-a-yubikey.md8
-rw-r--r--content/posts/2018/2018-09-13-hackerrank-solutions-python3-and-perl6-part-1.md16
7 files changed, 52 insertions, 52 deletions
diff --git a/content/posts/2017/2017-11-16-perl6-setting-up-a-raspberry-perl.md b/content/posts/2017/2017-11-16-perl6-setting-up-a-raspberry-perl.md
index c9b029f..2f5841e 100644
--- a/content/posts/2017/2017-11-16-perl6-setting-up-a-raspberry-perl.md
+++ b/content/posts/2017/2017-11-16-perl6-setting-up-a-raspberry-perl.md
@@ -15,7 +15,7 @@ In this tutorial I'll get you through setting up a Raspberry Pi with
versions should work fine too. However, older versions are slower, so it might
take a bit longer to install completely.
-{< admonition title="Note" >}
+{{< admonition title="Note" >}}
For those who have never had a Raspberry Pi before, you will need
the following:
@@ -24,7 +24,7 @@ the following:
- SD card of at least 4gb, but I would advise at least 8gb
- Monitor with HDMI cable
- Keyboard
-{< / admonition >}
+{{< / admonition >}}
Perl 6 will be installed using
[https://github.com/tadzik/rakudobrew](Rakudobrew), which I'll also be using to
diff --git a/content/posts/2017/2017-12-21-funding-yourself-as-free-software-developer.md b/content/posts/2017/2017-12-21-funding-yourself-as-free-software-developer.md
index ee68582..32f80f1 100644
--- a/content/posts/2017/2017-12-21-funding-yourself-as-free-software-developer.md
+++ b/content/posts/2017/2017-12-21-funding-yourself-as-free-software-developer.md
@@ -24,10 +24,10 @@ more useful for procuring a stable income.
### BountySource
-{< admonition title="Warning" >}
+{{< admonition title="Warning" >}}
- Requires 3rd-party [/blog/2017-12-17/on-cloudflare/](Cloudflare)-hosted
JavaScript sources to function.
-{< / admonition >}
+{{< / admonition >}}
BountySource lets people donate money towards an issue on Github your projects.
Once an issue gets fixed, you can claim the "bounty" that was on this issue.
@@ -71,10 +71,10 @@ You can find Liberapay at https://liberapay.com/.
### MakerSupport
-{< admonition title="Warning" >}
+{{< admonition title="Warning" >}}
- The site requires a 3rd-party hosted jQuery.
- You have to solve a Google reCaptcha in order to register a new account.
-{< / admonition >}
+{{< / admonition >}}
MakerSupport seems to be another option, aimed at content creators who might
need freedom of speech more than others. It seems to be less focused on
@@ -102,20 +102,20 @@ requests. Secondly, their error when uploading a "wrong" format is also not
very user friendly, as it won't give you any details on why it's disallowed,
nor what images are allowed instead.
-{< admonition title="Note" >}
+{{< admonition title="Note" >}}
It seems they check the extension of the uploaded image's filename. As far as I
can tell, you're allowed to upload files that end with `.jpg` and `.png`.
-{< / admonition >}
+{{< / admonition >}}
You can find MakerSupport at https://www.makersupport.com/.
### Patreon
-{< admonition title="Warning" >}
+{{< admonition title="Warning" >}}
- Requires 3rd-party link:/articles/on-cloudflare[Cloudflare]-hosted
JavaScript sources to function.
- You have to solve a Google reCaptcha in order to register a new account.
-{< / admonition >}
+{{< / admonition >}}
Patreon is possibly the most famous donation-based funding platform available
right now. Its popularity is a good thing, since this means there's probably
@@ -164,10 +164,10 @@ project, they won't be able to give any kind of appreciation for it. Use social
media outlets, public forums, mailing lists, anything! Tell them what you made,
why it's useful and how they could use it to improve their digital life.
-{< admonition title="Warning" >}
+{{< admonition title="Warning" >}}
Ofcourse, don't spam it to unrelated communication channels. This will only
backfire.
-{< / admonition >}
+{{< / admonition >}}
### Using the rewards system
@@ -206,10 +206,10 @@ few do appreciate having this information available to them.
It can be as simple as adding a `/donate` link to your site where you explain
how to donate to you, and what you do with the donation money.
-{< admonition title="Warning" >}
+{{< admonition title="Warning" >}}
Don't let it turn into an annoying advertisement though, this will surely have
an opposite effect.
-{< / admonition >}
+{{< / admonition >}}
## Further reading
diff --git a/content/posts/2018/2018-03-20-perl6-introduction-to-application-programming.md b/content/posts/2018/2018-03-20-perl6-introduction-to-application-programming.md
index 30912c9..21c4298 100644
--- a/content/posts/2018/2018-03-20-perl6-introduction-to-application-programming.md
+++ b/content/posts/2018/2018-03-20-perl6-introduction-to-application-programming.md
@@ -43,10 +43,10 @@ So we'll start by installing this module through `zef`.
$ zef install App::Assixt
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
You may need to rehash your `$PATH` as well, which can be done using `hash -r`
on `bash`, or `rehash` for `zsh`. For other shells, consult your manual.
-{< / admonition >}
+{{< / admonition >}}
Next up, we can use `assixt` to create the new skeleton of our application,
with the `new` subcommand. This will ask for some user input, which will be
@@ -168,7 +168,7 @@ subtest "Illegal rolls", {
}
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
Perl 6 allows mathematical characters to make your code more concise, as with
the ≤ in the above block. If you use http://www.vim.org/[vim], you can make use
of the https://github.com/vim-perl/vim-perl6[vim-perl6] plugin, which has an
@@ -181,7 +181,7 @@ If that's not an option, you can use a
https://en.wikipedia.org/wiki/Compose_key[compose key]. If that is not viable
either, you can also stick to using the ascii-based ops. Perl 6 supports both
of them.
-{< / admonition >}
+{{< / admonition >}}
This will run 53 tests, split up in two
[https://docs.perl6.org/language/testing#Grouping_tests](subtests). Subtests are
@@ -216,12 +216,12 @@ You might notice the tests are currently failing, which is correct. The
`Local::App::Dicer` module doesn't exist yet to test against. We'll be working
on that next.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
For those interested, the command run by `assixt test` is `prove -e "perl6
-Ilib" t`. This will include the `lib` directory into the `PERL6PATH` to be
able to access the libraries we'll be making. The `t` argument specifies the
directory containing the tests.
-{< / admonition >}
+{{< / admonition >}}
## Creating the library
@@ -262,11 +262,11 @@ exactly that. Let's start with the signature, which tells the compiler the name
of the subroutine, which arguments it accepts, their types and what type the
subroutine will return.
-{< admonition title="tip" >}
+{{< admonition title="tip" >}}
Perl 6 is gradually typed, so all type information is optional. The subroutine
arguments are optional too, but you will rarely want a subroutine that doesn't
have an argument list.
-{< / admonition >}
+{{< / admonition >}}
```raku
sub roll($sides) is export
@@ -407,11 +407,11 @@ sub MAIN(Int:D $dice, Int:D $sides where { $dice > 0 && $sides > 0 })
}
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
Just like the `≤` character, Perl 6 allows to use the proper multiplication
character `×` (this is not the letter `x`!). You can use the more widely known
`*` for multiplication as well.
-{< / admonition >}
+{{< / admonition >}}
If you run the program with the arguments `2` and `20` now, you'll get a random
number between 2 and 40, just like we expect:
@@ -767,8 +767,8 @@ $ zef install .
This will resolve the dependencies of the local module, and then install it.
You should now be able to run `dicer` from anywhere.
-{< admonition title="warning" >}
+{{< admonition title="warning" >}}
With most shells, you have to "rehash" your `$PATH` as well. On `bash`, this is
done with `hash -r`, on `zsh` it's `rehash`. If you're using any other shell,
please consult the manual.
-{< / admonition >}
+{{< / admonition >}}
diff --git a/content/posts/2018/2018-05-07-sparrowdo-getting-started.md b/content/posts/2018/2018-05-07-sparrowdo-getting-started.md
index b75de3a..aec4fdf 100644
--- a/content/posts/2018/2018-05-07-sparrowdo-getting-started.md
+++ b/content/posts/2018/2018-05-07-sparrowdo-getting-started.md
@@ -77,10 +77,10 @@ This is Rakudo Star version 2018.04.1 built on MoarVM version 2018.04.1
implementing Perl 6.c.
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
If there's a newer version available of Rakudo Star, the version numbers given
by `perl6 -v` will differ for you.
-{< / admonition >}
+{{< / admonition >}}
### Installing Sparrowdo with zef
@@ -105,10 +105,10 @@ option to do this automatically.
sparrowdo --bootstrap
```
-{< admonition title="tip" >}
+{{< admonition title="tip" >}}
If you wish to bootstrap a remote system, you can use the `--host` option to
specify the system. For example: `sparrowdo --host=192.168.1.2 --bootstrap`.
-{< / admonition >}
+{{< / admonition >}}
Now your system is ready to be configured automatically using Sparrowdo!
@@ -124,11 +124,11 @@ To make our sample, we'll create a new directory to work in, so we have clean
directory that can be shared easily. You can also keep this directory under
version control, so you can distribute the `sparrowfile` with all its templates.
-{< admonition title="tip" >}
+{{< admonition title="tip" >}}
If you just want to create an empty directory to test things in, without
"polluting" the rest of your system, just call `cd -- "$(mktemp -d)"`. This will
create a temporary directory and change the working directory to there.
-{< / admonition >}
+{{< / admonition >}}
I'll be using `~/.local/sparrowdo/local-dns` to work in, as I'll be setting up a
local dns cache with [http://www.thekelleys.org.uk/dnsmasq/doc.html](dnsmasq)
@@ -209,10 +209,10 @@ command with `--local_mode` and wait.
sparrowdo --local_mode
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
If you want to run this on a remote machine to configure that one instead, you
can use `--host=<ip>` instead of `--local_mode`.
-{< admonition >}
+{{< admonition >}}
You can check whether it actually worked by inspecting the files in
`/etc/dnsmasq.d` and your `/etc/resolv.conf`. The easiest way to check their
diff --git a/content/posts/2018/2018-08-15-the-perl-conference-in-glasgow.md b/content/posts/2018/2018-08-15-the-perl-conference-in-glasgow.md
index 0716bcc..060ed2a 100644
--- a/content/posts/2018/2018-08-15-the-perl-conference-in-glasgow.md
+++ b/content/posts/2018/2018-08-15-the-perl-conference-in-glasgow.md
@@ -13,14 +13,14 @@ I've attended a number of presentations there. On some of these, I have some
feedback or comments. These talks, and the feedback I have for them, are
detailed in this blog post.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
The first talk I cover is not so much about Perl, but more about politics, as
the talk was mostly about the speaker's ideology. If this does not interest you,
I'd suggest you skip the [#discourse-without-drama](Discourse Without Drama)
section, and head straight to the
[#european-perl-mongers-organiser-s-forum-2018](European Perl Mongers
Organiser's Forum 2018).
-{< / admonition >}
+{{< / admonition >}}
## Discourse Without Drama
@@ -30,13 +30,13 @@ skeptical of such presentations from the get-go. Nonetheless, I did stay until
the end and tried to give it a fair shot. However, I cannot sit idle while she
tries to force her ideology on this community I care very deeply about.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
I am not against the concept of diversity, I wholly support the idea of equal
opportunities. What I do not accept is the idea of equal outcome, or forced
diversity based on physical traits. This is what I refer to with "the diversity
ideology". I also don't think anyone has a right not to be offended, as this is
impossible to achieve in the real world.
-{< / admonition >}
+{{< / admonition >}}
One of the things that stood out to me is that the speaker tells us not to use
logical fallacies to condemn her ideology. This on itself I can easily agree
@@ -82,9 +82,9 @@ people for the sake of not offending anyone can effectively halt creativity and
the exchange of ideas. There was also an interesting quote written on one of
the walls of the venue:
-{< quote attribution="Oscar Romero" >}
+{{< quote attribution="Oscar Romero" >}}
Aspire not to have more, but to be more...
-{< / quote >}
+{{< / quote >}}
Don't try to add meaningless documents such as a code of conduct, which more
often than not hurts a community instead of improving it. Try to be a better
diff --git a/content/posts/2018/2018-09-04-setting-up-pgp-with-a-yubikey.md b/content/posts/2018/2018-09-04-setting-up-pgp-with-a-yubikey.md
index 314ba09..278a4d3 100644
--- a/content/posts/2018/2018-09-04-setting-up-pgp-with-a-yubikey.md
+++ b/content/posts/2018/2018-09-04-setting-up-pgp-with-a-yubikey.md
@@ -21,10 +21,10 @@ In this blogpost, I will detail how I set up my security policies in the hopes
it will be able to help out other people looking to improve their security, and
to get feedback to improve my set up as well.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
I am using the Yubikey 4. If you're using another version, some steps may
differ.
-{< / admonition >}
+{{< / admonition >}}
## Installing required software
@@ -287,10 +287,10 @@ need the `cryptsetup` utility to apply the encryption, and to unlock the drive.
You can find out the device name from `dmesg` or `lsblk`. Once you know it,
encrypt the drive with the `luksFormat` subcommand.
-{< admonition title="warning" >}
+{{< admonition title="warning" >}}
Using the wrong name for the device can irrecoverably destroy data from another
drive!
-{< / admonition >}
+{{< / admonition >}}
```txt
cryptsetup luksFormat /dev/sdb
diff --git a/content/posts/2018/2018-09-13-hackerrank-solutions-python3-and-perl6-part-1.md b/content/posts/2018/2018-09-13-hackerrank-solutions-python3-and-perl6-part-1.md
index c7418e7..c3f2aee 100644
--- a/content/posts/2018/2018-09-13-hackerrank-solutions-python3-and-perl6-part-1.md
+++ b/content/posts/2018/2018-09-13-hackerrank-solutions-python3-and-perl6-part-1.md
@@ -19,13 +19,13 @@ I will show solutions to some challenges to show the differences. I hope that I
can show that Perl doesn't have to be the "write only" language that many
people make it out to be.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
I am _much_ more proficient in the Perl 6 programming language than in Python
(2 or 3), so I might not always use the most optimal solutions in the Python
variants. Suggestions are welcome via email, though I most likely won't update
this post with better solutions. I ofcourse also welcome feedback on the Perl 6
solutions!
-{< / admonition >}
+{{< / admonition >}}
## Challenges
@@ -102,11 +102,11 @@ sub simple-array-sum (@ar) {
}
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
After publishing this post I have learned that both Python 3 and Perl 6 have a
`.sum` function that can also be called on the array, simplifying the code in
both languages.
-{< / admonition >}
+{{< / admonition >}}
### Compare the Triplets
@@ -153,10 +153,10 @@ Both of these loops could use a `continue` (or `next` in Perl 6) to skip the
second `if` in case the first `if` was true, but for readability I chose not
to.
-{< admonition title="note" >}
+{{< admonition title="note" >}}
After publishing this post I learned that Python 3 also supports the inline if
syntax, just like Perl 6, so I could've used this in Python 3 as well.
-{< / admonition >}
+{{< / admonition >}}
### A Very Big Sum
@@ -368,11 +368,11 @@ sub birthday-cake-candles (@ar) {
}
```
-{< admonition title="note" >}
+{{< admonition title="note" >}}
On IRC, someone showed me a clean solution in Python 3: `return
ar.count(max(ar))`. This feels like a much cleaner solution than what I had
created.
-{< / admonition >}
+{{< / admonition >}}
### Time Conversion