Blog¶
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book.
Metadata¶
Summary delimiter¶
In Markdown, <!-- more --> is a common "excerpt" or "summary" delimiter used by certain platforms or static site generators to indicate where a post or article should be truncated when displayed in a list or index.
Uploading images by custom command¶
Workflow
- Convert a png, jpg into webp format by
cwebp - Add a watermark at bottom-right corner of the webp by
magick - Rename the webp with its md5 hash by
md5sum - Upload the webp file to SM.MS by
picgo
Installation:
-
Install md5sha1sum, WebP, and ImageMagick by homebrew
-
brew install md5sha1sum webp imagemagick -
Calculate the MD5 checksum for one or more files:
md5sum path/to/file1 path/to/file2 ... -
Compress a WebP file with default settings (q = 75) to the [o]utput file:
cwebp path/to/image_file -o path/to/output.webp -
Add your own watermark at bottom-right corner:
magick path/to/input.webp -pointsize 30 -fill white -gravity SouthEast -annotate +10+10 'your watermark' path/to/output.webp
-
-
Install Picgo-Core
-
npm install picgo -g -
Upload an image from a specific path:
picgo upload path/to/image
-
-
Register SM.MS https://sm.ms/ or https://smms.app/
-
Generate a secret token in SM.MS
-
Interactively select SM.MS hosting service:
picgo set uploader
-
-
Write a bash script:
./upload.sh image.jpg- Print the fifth column (a.k.a. field) in a space-separated file:
awk '{print $5}' path/to/file
- Print the fifth column (a.k.a. field) in a space-separated file:
-
Here are the test image, watermark is at bottom-right corner:
Image caption
Edit with Typora¶
- Set indent size to 4
- List
- Nested list
- Nested list
- Set image uploader to custom command
