Skip to content

Commit

Permalink
Merge pull request #9 from maciejzj/develop
Browse files Browse the repository at this point in the history
Release for v0.2.0
  • Loading branch information
maciejzj authored May 21, 2024
2 parents f5abe47 + ed4e448 commit 6922128
Show file tree
Hide file tree
Showing 8 changed files with 567 additions and 3 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,9 @@ Credentials: https://github.com/maciejzj/ssb

## Other tips

Stylesheets for theming can be found
[here](https://github.com/maciejzj/ssb-themes).
Stylesheets for theming can be found inside the `themes` directory. The path to
a stylesheet is specified in the header html file, be default it is
`styles.css`.

You can grab the following Makefile starter to use ssb in a more comfortable
way:
Expand Down
2 changes: 1 addition & 1 deletion ssb
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,7 @@ make_html_files()
# Ignore the suggestion because tempf can be expanded immediately
# shellcheck disable=SC2064
trap "rm $tempf" 0 2 3 15
append_posts_list "$posts" | cat "$md_file" - | "$MD_RENDERER" > "$tempf"
append_posts_list "$posts" | cat "$md_file" - | eval "$MD_RENDERER" > "$tempf"
cat "$HEADER_PATH" "$tempf" "$FOOTER_PATH" > "$output_file"
done
}
Expand Down
2 changes: 2 additions & 0 deletions themes/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
/*.html
/*.css
9 changes: 9 additions & 0 deletions themes/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Themes for ssb

Path to a stylesheet is specified in the ssb html header file. The default one
looks for `styles.css` in the header's directory.

## Running quick visual tests of the themes

Use the `run_test` script passing the path to the desired theme as an argument.
This script uses ssb version accessed via PATH.
54 changes: 54 additions & 0 deletions themes/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,54 @@
# Header 1
## Header 2
### Header 3
#### Header 4
##### Header 5

* Bullet point 1
* Bulet point 2
* Bullet point 3

1. Ordered list first
2. Ordered list second
3. Ordered list third

A [link](https://maciejzj.xyz) to a website.

| Column 1 | Column 2 |
| -------- | -------- |
| Value 1 | Row 1 |
| Value 2 | Row 2 |
| Value 3 | Row 3 |

> A quote block.
A piece of *emph* text.

A piece of **strong** text.

![An image](https://api.culture.pl/sites/default/files/styles/260_auto_aspect/public/images/imported/sztuki%20wizualne/portrety/Jarema_mari/jerema_mairia_rolke_ag.jpg?itok=K7cmrkcF)

A ruler separating text.

---

Preformatted code/verbatim:

```
git filter-branch --env-filter '
WRONG_EMAIL="<WRONG_EMAIL>"
NEW_NAME="<NEW_NAME>"
NEW_EMAIL="<NEW_EMAIL>"
if [ "$GIT_COMMITTER_EMAIL" = "$WRONG_EMAIL" ]
then
export GIT_COMMITTER_NAME="$NEW_NAME"
export GIT_COMMITTER_EMAIL="$NEW_EMAIL"
fi
if [ "$GIT_AUTHOR_EMAIL" = "$WRONG_EMAIL" ]
then
export GIT_AUTHOR_NAME="$NEW_NAME"
export GIT_AUTHOR_EMAIL="$NEW_EMAIL"
fi
' --tag-name-filter cat -- --branches --tags
```
9 changes: 9 additions & 0 deletions themes/run_test
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/usr/bin/env sh
# Usage: run_test <path_to_css>

set -eu

rm -f styles.css
ssb -g
ln -fs "$1" styles.css
ssb -d index.md
Loading

0 comments on commit 6922128

Please sign in to comment.