Skip to content

Commit 57626c2

Browse files
committed
build: re-organize build workflow
1 parent 86b36b1 commit 57626c2

File tree

6 files changed

+34
-18
lines changed

6 files changed

+34
-18
lines changed

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
# mark as generated files for github stats & diffs
2+
theme.css linguist-generated

.github/workflows/build-and-bump.yml

Lines changed: 18 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,13 @@ permissions:
1313

1414
#───────────────────────────────────────────────────────────────────────────────
1515

16+
# 1. for lightning-css (also lowers syntax to before css-nesting) https://caniuse.com/css-nesting
17+
# 2. for doiuse
18+
env:
19+
BROWSERLIST: "chrome 108"
20+
21+
#───────────────────────────────────────────────────────────────────────────────
22+
1623
jobs:
1724
bump:
1825
runs-on: macos-latest
@@ -39,25 +46,33 @@ jobs:
3946
4047
# minification & syntax-lowering https://lightningcss.dev/transpilation.html
4148
npm install
42-
export BROWSERSLIST="chrome 108" # lowers syntax to before css-nesting https://caniuse.com/css-nesting
49+
export BROWSERSLIST="{{ env.BROWSERSLIST }}}"
50+
echo "Syntax lowering for: $BROWSERSLIST"
4351
npx lightningcss --minify --browserslist \
4452
--output-file="./temp.css" -- "./temp.css" || exit 1
4553
46-
# merge header, css code, and style settings into `theme.css`
54+
# remove old file
55+
rm theme.css
56+
57+
# add header
4758
echo "/*" >> ./theme.css
4859
cat ./source/header.txt >> ./theme.css
4960
echo "*/" >> ./theme.css
5061
51-
cat ./temp.css >> ./theme.css
62+
# add css
63+
cat ./temp.css >> ./theme.css
5264
rm temp.css
5365
66+
# add style settings
5467
echo "" >> ./theme.css
5568
echo "/* @settings" >> ./theme.css
5669
cat ./source/style-settings.yaml >> theme.css
5770
echo "*/" >> theme.css
5871
5972
- name: check for unsupported features
6073
run: |
74+
export BROWSERSLIST="{{ env.BROWSERSLIST }}}"
75+
echo "doiuse check for: $BROWSERSLIST"
6176
violations=$(npx doiuse --browsers="$BROWSERSLIST" \
6277
--config="./.doiuse-ignore.json" theme.css)
6378
if [[ -n "$violations" ]]; then # `doiuse` does not exit with non-zero code

README.md

Lines changed: 3 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Shimmering Focus ⟡
2-
![Downloads in Obsidian](https://img.shields.io/badge/downloads-248639-6E4E9B?style=plastic&logo=obsidian&color=%23483699)
2+
![Downloads in Obsidian](https://img.shields.io/badge/downloads-248648-6E4E9B?style=plastic&logo=obsidian&color=%23483699)
33
![GitHub stars](https://img.shields.io/github/stars/chrisgrieser/shimmering-focus?style=plastic&label=%E2%98%85%20Stars)
44
![Last commit](https://img.shields.io/github/last-commit/chrisgrieser/shimmering-focus?style=plastic)
55

@@ -56,7 +56,8 @@ downloaded theme in the Obsidian theme store.
5656
- **Alternative color schemes** submitted by the community are available by
5757
using the Style Settings Plugin.
5858
- **For writers**: Emphasis of **Pandoc citations** and **footnotes**, extensive
59-
styling for the [Longform Plugin](https://obsidian.md/plugins?id=longform).
59+
styling for the [Longform Plugin](https://obsidian.md/plugins?id=longform) and
60+
notes using `cssclasses: writing`.
6061
- **For vim users**: Explicit styling of Obsidian's Vim Mode, including various
6162
settings such as relative line numbers or cursorline highlights.
6263
- **High customizability:** There are over a hundred customization options
@@ -73,13 +74,6 @@ Plugin](https://obsidian.md/plugins?id=obsidian-style-settings) is installed,
7374
- Toggle readable line length (requires the `Readable line length` setting in
7475
Obsidian to be enabled.)
7576

76-
### Settings for writers
77-
- Add `cssclasses: writing` to your frontmatter to enable writing-specific
78-
styling for that note, such as a serif font and justified text. The same
79-
styling is also applied to all scenes from the [longform plugin](http://github.com/kevboh/longform).
80-
- You can customize the styling with the [Style Settings
81-
Plugin](https://obsidian.md/plugins?id=obsidian-style-settings).
82-
8377
## Advanced customization
8478

8579
### Create your own color scheme

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "Shimmering Focus",
33
"author": "pseudometa aka Chris Grieser",
4-
"version": "5.46",
4+
"version": "5.49",
55
"minAppVersion": "1.6.0",
66
"authorUrl": "https://github.com/chrisgrieser/shimmering-focus",
77
"helpUrl": "https://github.com/chrisgrieser/shimmering-focus#readme",

source/4-user-interface/sidebars.css

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,6 @@
1818
/** Sidebar Headers Hidden (Tab Headers)
1919
──────────────────────────────────────────────────── */
2020

21-
body:not(.show-sidebar-header-buttons) {
22-
--sidebar-tabs-unhovered-height: 10px;
23-
}
24-
2521
/* WINDOWS / LINUX */
2622
/* fix sidebar header buttons not being clickable see #247 */
2723
body:is(.mod-windows, .mod-linux) {
@@ -60,6 +56,7 @@ body:not(.show-sidebar-header-buttons)
6056
:is(.mod-left-split, .mod-right-split)
6157
.workspace-tabs:not(.mod-top)
6258
.workspace-tab-header-container:not(:hover) {
59+
--sidebar-tabs-unhovered-height: 10px;
6360
height: var(--sidebar-tabs-unhovered-height);
6461
}
6562

theme.css

Lines changed: 9 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)