Writings
+ ++
-
+
- + 2025-02-23 我的第一篇博客 + +
diff --git a/LICENCE b/LICENCE new file mode 100644 index 0000000..a47a616 --- /dev/null +++ b/LICENCE @@ -0,0 +1,4 @@ +No Copyright +The person who associated a work with this deed has dedicated the work to the public domain by waiving all of his or her rights to the work worldwide under copyright law, including all related and neighboring rights, to the extent allowed by law. + +You can copy, modify, distribute and perform the work, even for commercial purposes, all without asking permission. See Other Information below. diff --git a/README.md b/README.md index 3824939..d761a0c 100644 --- a/README.md +++ b/README.md @@ -1,3 +1,35 @@ -# shblog +Generate blog by ShellScript +============================= + +Run +--- + +``` +make serve +``` + +Open url http://localhost:8999 to view. + +Build +--- + +``` +make +``` + +Write post +--- + +``` +make post +``` + +Notes: +====== + +[01] You should write code by yourself. + +[02] Article suffix is txt. The first row is the time, the second row is the title. + +[03] Use the GNU version of `sed`. -Make blog website by shellscripts \ No newline at end of file diff --git a/makefile b/makefile new file mode 100644 index 0000000..284c8e4 --- /dev/null +++ b/makefile @@ -0,0 +1,16 @@ +.DEFAULT: build + +.PHONY: build +build: + @echo "Building ..." + @mkdir tmp + @echo "Loading" + @sh src/script/xml.sh > public/feed.xml + @sh src/script/home.sh > public/index.html + @sh src/script/list.sh > public/archive.html + @sh src/script/page.sh + @rm -rf tmp + @echo "Static files are saved at public/" + @echo "\033[36mSuccess!\033[0m" +push: build + @rm -rf /var/www/htdocs/ity.moe && cp -r public /var/www/htdocs/ity.moe diff --git a/posts/chat.txt b/posts/chat.txt new file mode 100644 index 0000000..55becd6 --- /dev/null +++ b/posts/chat.txt @@ -0,0 +1,5 @@ +2025/02/23 +我的第一篇博客 + +当然是 2025 年的第一篇啦~ + diff --git a/public/archive.html b/public/archive.html new file mode 100644 index 0000000..a6dd2b2 --- /dev/null +++ b/public/archive.html @@ -0,0 +1,15 @@ +
+
Stay kind, stay pure
+I love nature and my dream is to explore the universe!
+ ++当然是 2025 年的第一篇啦~ +
+