From b0b8f7ffbf563f341745e86bfe85f080f6a8db27 Mon Sep 17 00:00:00 2001 From: Mitja Felicijan Date: Wed, 8 Dec 2021 11:59:37 +0100 Subject: A bunch of changes --- Makefile | 10 +- assets/dfd-rice/install-00.png | Bin 0 -> 35695 bytes assets/dfd-rice/install-01.png | Bin 0 -> 28042 bytes assets/dfd-rice/install-02.png | Bin 0 -> 21638 bytes assets/dfd-rice/install-03.png | Bin 0 -> 34698 bytes assets/dfd-rice/install-04.png | Bin 0 -> 28346 bytes assets/dfd-rice/install-05.png | Bin 0 -> 13755 bytes assets/dfd-rice/installation.svg | 1554 ++++++++++++++++++++ assets/dfd-rice/layout.png | Bin 0 -> 9072 bytes assets/dfd-rice/layout.svg | 132 ++ .../dna-sequence/chart-encoding-speed.png.dith.gif | Bin 3758 -> 0 bytes assets/dna-sequence/chart-file-sizes.png.dith.gif | Bin 3701 -> 0 bytes assets/dna-sequence/dna-basics.jpg.dith.gif | Bin 10044 -> 0 bytes assets/dna-sequence/quote.png.dith.gif | Bin 2336 -> 0 bytes .../dna-sequence/sample-binary-file.png.dith.gif | Bin 9300 -> 0 bytes assets/dna-sequence/sample.png.dith.gif | Bin 60908 -> 0 bytes assets/do-fuse/fuse-droplets.png.dith.gif | Bin 4193 -> 0 bytes assets/do-fuse/fuse-spaces.png.dith.gif | Bin 3327 -> 0 bytes assets/dropbox-sync/dropbox-spaces.png.dith.gif | Bin 4074 -> 0 bytes assets/esp8366-micropython/boards.jpg.dith.gif | Bin 26238 -> 0 bytes assets/general/favicon.png.dith.gif | Bin 332 -> 0 bytes assets/goaccess/goaccess-dash-html.png.dith.gif | Bin 4783 -> 0 bytes assets/goaccess/goaccess-dash-term.png.dith.gif | Bin 7606 -> 0 bytes assets/iot-application/iot-app-output.png.dith.gif | Bin 6198 -> 0 bytes .../iot-application/iot-rest-example.png.dith.gif | Bin 3620 -> 0 bytes assets/iot-application/iot-sqlite-db.png.dith.gif | Bin 14622 -> 0 bytes assets/iot-application/kcachegrind.png.dith.gif | Bin 4476 -> 0 bytes .../iot-application/profiling-viewer.png.dith.gif | Bin 11283 -> 0 bytes assets/iot-application/snakeviz.png.dith.gif | Bin 4951 -> 0 bytes assets/profile-bind-error/error.jpg.dith.gif | Bin 11794 -> 0 bytes assets/python-profiling/kcachegrind.png.dith.gif | Bin 4476 -> 0 bytes .../python-profiling/profiling-viewer.png.dith.gif | Bin 11283 -> 0 bytes assets/python-profiling/snakeviz.png.dith.gif | Bin 4951 -> 0 bytes ...uardian-sa-title-desc-relationship.png.dith.gif | Bin 4695 -> 0 bytes assets/simple-pubsub-server/caniuse.png.dith.gif | Bin 10170 -> 0 bytes .../chrome-debugging.png.dith.gif | Bin 15615 -> 0 bytes .../pubsub-overview.png.dith.gif | Bin 5116 -> 0 bytes assets/world-clock/hardware.jpg.dith.gif | Bin 11351 -> 0 bytes assets/world-clock/world-clock.jpg.dith.gif | Bin 7940 -> 0 bytes ...01-13-most-likely-to-succeed-in-year-of-2011.md | 26 + posts/2012-03-09-led-technology-not-so-eco copy.md | 26 - ...ng-python-web-applications-with-visual-tools.md | 6 +- posts/2017-08-11-simple-iot-application.md | 6 +- ...digitalocean-spaces-object-storage-with-fuse.md | 4 +- ...01-03-encoding-binary-data-into-dna-sequence.md | 6 +- ...alysis-for-click-bait-detection-in-rss-feeds.md | 88 -- ...g-sentiment-analysis-for-clickbait-detection.md | 88 ++ posts/2020-03-22-simple-sse-based-pubsub-server.md | 6 +- posts/2020-09-06-esp-and-micropython.md | 2 +- posts/2020-09-08-bind-warning-on-login.md | 2 +- posts/2021-01-24-replacing-dropbox-with-s3.md | 2 +- posts/2021-01-25-goaccess.md | 4 +- posts/2021-06-26-simple-world-clock.md | 4 +- ...n-based-riced-up-distribution-for-developers.md | 143 ++ template/_meta.html | 2 +- template/_navigation.html | 2 + template/openring-build.html | 0 template/script.js | 20 +- template/style.css | 8 +- 59 files changed, 1988 insertions(+), 153 deletions(-) create mode 100644 assets/dfd-rice/install-00.png create mode 100644 assets/dfd-rice/install-01.png create mode 100644 assets/dfd-rice/install-02.png create mode 100644 assets/dfd-rice/install-03.png create mode 100644 assets/dfd-rice/install-04.png create mode 100644 assets/dfd-rice/install-05.png create mode 100644 assets/dfd-rice/installation.svg create mode 100644 assets/dfd-rice/layout.png create mode 100644 assets/dfd-rice/layout.svg delete mode 100644 assets/dna-sequence/chart-encoding-speed.png.dith.gif delete mode 100644 assets/dna-sequence/chart-file-sizes.png.dith.gif delete mode 100644 assets/dna-sequence/dna-basics.jpg.dith.gif delete mode 100644 assets/dna-sequence/quote.png.dith.gif delete mode 100644 assets/dna-sequence/sample-binary-file.png.dith.gif delete mode 100644 assets/dna-sequence/sample.png.dith.gif delete mode 100644 assets/do-fuse/fuse-droplets.png.dith.gif delete mode 100644 assets/do-fuse/fuse-spaces.png.dith.gif delete mode 100644 assets/dropbox-sync/dropbox-spaces.png.dith.gif delete mode 100644 assets/esp8366-micropython/boards.jpg.dith.gif delete mode 100644 assets/general/favicon.png.dith.gif delete mode 100644 assets/goaccess/goaccess-dash-html.png.dith.gif delete mode 100644 assets/goaccess/goaccess-dash-term.png.dith.gif delete mode 100644 assets/iot-application/iot-app-output.png.dith.gif delete mode 100644 assets/iot-application/iot-rest-example.png.dith.gif delete mode 100644 assets/iot-application/iot-sqlite-db.png.dith.gif delete mode 100644 assets/iot-application/kcachegrind.png.dith.gif delete mode 100644 assets/iot-application/profiling-viewer.png.dith.gif delete mode 100644 assets/iot-application/snakeviz.png.dith.gif delete mode 100644 assets/profile-bind-error/error.jpg.dith.gif delete mode 100644 assets/python-profiling/kcachegrind.png.dith.gif delete mode 100644 assets/python-profiling/profiling-viewer.png.dith.gif delete mode 100644 assets/python-profiling/snakeviz.png.dith.gif delete mode 100644 assets/sentiment-analysis/guardian-sa-title-desc-relationship.png.dith.gif delete mode 100644 assets/simple-pubsub-server/caniuse.png.dith.gif delete mode 100644 assets/simple-pubsub-server/chrome-debugging.png.dith.gif delete mode 100644 assets/simple-pubsub-server/pubsub-overview.png.dith.gif delete mode 100644 assets/world-clock/hardware.jpg.dith.gif delete mode 100644 assets/world-clock/world-clock.jpg.dith.gif create mode 100755 posts/2011-01-13-most-likely-to-succeed-in-year-of-2011.md delete mode 100755 posts/2012-03-09-led-technology-not-so-eco copy.md delete mode 100644 posts/2019-10-19-using-sentiment-analysis-for-click-bait-detection-in-rss-feeds.md create mode 100644 posts/2019-10-19-using-sentiment-analysis-for-clickbait-detection.md create mode 100644 posts/2021-12-01-debian-based-riced-up-distribution-for-developers.md create mode 100644 template/openring-build.html diff --git a/Makefile b/Makefile index eade890..450f700 100644 --- a/Makefile +++ b/Makefile @@ -5,7 +5,10 @@ provision: go build \ go install -dev: +dither: + bash dither-images.sh + +openring: openring -l 165 -n 4 -p 1 \ -s https://cronokirby.com/posts/index.xml \ -s https://drewdevault.com/feed.xml \ @@ -13,10 +16,11 @@ dev: -s https://serokell.io/blog.rss.xml \ < template/openring.tmpl \ > template/openring-build.html + +dev: openring alternator --watch build: - bash dither-images.sh mkdir -p public openring -l 165 -n 4 -p 1 \ -s https://cronokirby.com/posts/index.xml \ @@ -28,7 +32,7 @@ build: alternator --build rm template/openring-build.html - cp yapyap/* public/ deploy: build cd public && scp -r * root@165.22.87.180:/var/www/html/mitjafelicijan.com/ + ssh root@165.22.87.180 chown www-data:www-data /var/www/html/mitjafelicijan.com/ -Rf diff --git a/assets/dfd-rice/install-00.png b/assets/dfd-rice/install-00.png new file mode 100644 index 0000000..2660f90 Binary files /dev/null and b/assets/dfd-rice/install-00.png differ diff --git a/assets/dfd-rice/install-01.png b/assets/dfd-rice/install-01.png new file mode 100644 index 0000000..1281be1 Binary files /dev/null and b/assets/dfd-rice/install-01.png differ diff --git a/assets/dfd-rice/install-02.png b/assets/dfd-rice/install-02.png new file mode 100644 index 0000000..9cac5e3 Binary files /dev/null and b/assets/dfd-rice/install-02.png differ diff --git a/assets/dfd-rice/install-03.png b/assets/dfd-rice/install-03.png new file mode 100644 index 0000000..dc7cbd1 Binary files /dev/null and b/assets/dfd-rice/install-03.png differ diff --git a/assets/dfd-rice/install-04.png b/assets/dfd-rice/install-04.png new file mode 100644 index 0000000..675a78f Binary files /dev/null and b/assets/dfd-rice/install-04.png differ diff --git a/assets/dfd-rice/install-05.png b/assets/dfd-rice/install-05.png new file mode 100644 index 0000000..8b580b9 Binary files /dev/null and b/assets/dfd-rice/install-05.png differ diff --git a/assets/dfd-rice/installation.svg b/assets/dfd-rice/installation.svg new file mode 100644 index 0000000..200b71b --- /dev/null +++ b/assets/dfd-rice/installation.svg @@ -0,0 +1,1554 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/assets/dfd-rice/layout.png b/assets/dfd-rice/layout.png new file mode 100644 index 0000000..a44d2cd Binary files /dev/null and b/assets/dfd-rice/layout.png differ diff --git a/assets/dfd-rice/layout.svg b/assets/dfd-rice/layout.svg new file mode 100644 index 0000000..880cab3 --- /dev/null +++ b/assets/dfd-rice/layout.svg @@ -0,0 +1,132 @@ + + + + + + + + + + + TERMINAL + + + BROWSER + + CODE EDITOR + TERMINAL + + + diff --git a/assets/dna-sequence/chart-encoding-speed.png.dith.gif b/assets/dna-sequence/chart-encoding-speed.png.dith.gif deleted file mode 100644 index 97cfaa9..0000000 Binary files a/assets/dna-sequence/chart-encoding-speed.png.dith.gif and /dev/null differ diff --git a/assets/dna-sequence/chart-file-sizes.png.dith.gif b/assets/dna-sequence/chart-file-sizes.png.dith.gif deleted file mode 100644 index 4074890..0000000 Binary files a/assets/dna-sequence/chart-file-sizes.png.dith.gif and /dev/null differ diff --git a/assets/dna-sequence/dna-basics.jpg.dith.gif b/assets/dna-sequence/dna-basics.jpg.dith.gif deleted file mode 100644 index b33745f..0000000 Binary files a/assets/dna-sequence/dna-basics.jpg.dith.gif and /dev/null differ diff --git a/assets/dna-sequence/quote.png.dith.gif b/assets/dna-sequence/quote.png.dith.gif deleted file mode 100644 index 11ead55..0000000 Binary files a/assets/dna-sequence/quote.png.dith.gif and /dev/null differ diff --git a/assets/dna-sequence/sample-binary-file.png.dith.gif b/assets/dna-sequence/sample-binary-file.png.dith.gif deleted file mode 100644 index 8d35c68..0000000 Binary files a/assets/dna-sequence/sample-binary-file.png.dith.gif and /dev/null differ diff --git a/assets/dna-sequence/sample.png.dith.gif b/assets/dna-sequence/sample.png.dith.gif deleted file mode 100644 index 269b77d..0000000 Binary files a/assets/dna-sequence/sample.png.dith.gif and /dev/null differ diff --git a/assets/do-fuse/fuse-droplets.png.dith.gif b/assets/do-fuse/fuse-droplets.png.dith.gif deleted file mode 100644 index 62d8ba2..0000000 Binary files a/assets/do-fuse/fuse-droplets.png.dith.gif and /dev/null differ diff --git a/assets/do-fuse/fuse-spaces.png.dith.gif b/assets/do-fuse/fuse-spaces.png.dith.gif deleted file mode 100644 index 1f7786e..0000000 Binary files a/assets/do-fuse/fuse-spaces.png.dith.gif and /dev/null differ diff --git a/assets/dropbox-sync/dropbox-spaces.png.dith.gif b/assets/dropbox-sync/dropbox-spaces.png.dith.gif deleted file mode 100644 index 2fb9245..0000000 Binary files a/assets/dropbox-sync/dropbox-spaces.png.dith.gif and /dev/null differ diff --git a/assets/esp8366-micropython/boards.jpg.dith.gif b/assets/esp8366-micropython/boards.jpg.dith.gif deleted file mode 100644 index 36f67ef..0000000 Binary files a/assets/esp8366-micropython/boards.jpg.dith.gif and /dev/null differ diff --git a/assets/general/favicon.png.dith.gif b/assets/general/favicon.png.dith.gif deleted file mode 100644 index 740f1b7..0000000 Binary files a/assets/general/favicon.png.dith.gif and /dev/null differ diff --git a/assets/goaccess/goaccess-dash-html.png.dith.gif b/assets/goaccess/goaccess-dash-html.png.dith.gif deleted file mode 100644 index ea6a26a..0000000 Binary files a/assets/goaccess/goaccess-dash-html.png.dith.gif and /dev/null differ diff --git a/assets/goaccess/goaccess-dash-term.png.dith.gif b/assets/goaccess/goaccess-dash-term.png.dith.gif deleted file mode 100644 index bc26010..0000000 Binary files a/assets/goaccess/goaccess-dash-term.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/iot-app-output.png.dith.gif b/assets/iot-application/iot-app-output.png.dith.gif deleted file mode 100644 index 02b3762..0000000 Binary files a/assets/iot-application/iot-app-output.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/iot-rest-example.png.dith.gif b/assets/iot-application/iot-rest-example.png.dith.gif deleted file mode 100644 index cb1d122..0000000 Binary files a/assets/iot-application/iot-rest-example.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/iot-sqlite-db.png.dith.gif b/assets/iot-application/iot-sqlite-db.png.dith.gif deleted file mode 100644 index 4c272f1..0000000 Binary files a/assets/iot-application/iot-sqlite-db.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/kcachegrind.png.dith.gif b/assets/iot-application/kcachegrind.png.dith.gif deleted file mode 100644 index 50d6473..0000000 Binary files a/assets/iot-application/kcachegrind.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/profiling-viewer.png.dith.gif b/assets/iot-application/profiling-viewer.png.dith.gif deleted file mode 100644 index 0023947..0000000 Binary files a/assets/iot-application/profiling-viewer.png.dith.gif and /dev/null differ diff --git a/assets/iot-application/snakeviz.png.dith.gif b/assets/iot-application/snakeviz.png.dith.gif deleted file mode 100644 index 7e25d0f..0000000 Binary files a/assets/iot-application/snakeviz.png.dith.gif and /dev/null differ diff --git a/assets/profile-bind-error/error.jpg.dith.gif b/assets/profile-bind-error/error.jpg.dith.gif deleted file mode 100644 index 4cc36e5..0000000 Binary files a/assets/profile-bind-error/error.jpg.dith.gif and /dev/null differ diff --git a/assets/python-profiling/kcachegrind.png.dith.gif b/assets/python-profiling/kcachegrind.png.dith.gif deleted file mode 100644 index 50d6473..0000000 Binary files a/assets/python-profiling/kcachegrind.png.dith.gif and /dev/null differ diff --git a/assets/python-profiling/profiling-viewer.png.dith.gif b/assets/python-profiling/profiling-viewer.png.dith.gif deleted file mode 100644 index 0023947..0000000 Binary files a/assets/python-profiling/profiling-viewer.png.dith.gif and /dev/null differ diff --git a/assets/python-profiling/snakeviz.png.dith.gif b/assets/python-profiling/snakeviz.png.dith.gif deleted file mode 100644 index 7e25d0f..0000000 Binary files a/assets/python-profiling/snakeviz.png.dith.gif and /dev/null differ diff --git a/assets/sentiment-analysis/guardian-sa-title-desc-relationship.png.dith.gif b/assets/sentiment-analysis/guardian-sa-title-desc-relationship.png.dith.gif deleted file mode 100644 index cb7644c..0000000 Binary files a/assets/sentiment-analysis/guardian-sa-title-desc-relationship.png.dith.gif and /dev/null differ diff --git a/assets/simple-pubsub-server/caniuse.png.dith.gif b/assets/simple-pubsub-server/caniuse.png.dith.gif deleted file mode 100644 index 204c156..0000000 Binary files a/assets/simple-pubsub-server/caniuse.png.dith.gif and /dev/null differ diff --git a/assets/simple-pubsub-server/chrome-debugging.png.dith.gif b/assets/simple-pubsub-server/chrome-debugging.png.dith.gif deleted file mode 100644 index 898a6d0..0000000 Binary files a/assets/simple-pubsub-server/chrome-debugging.png.dith.gif and /dev/null differ diff --git a/assets/simple-pubsub-server/pubsub-overview.png.dith.gif b/assets/simple-pubsub-server/pubsub-overview.png.dith.gif deleted file mode 100644 index c642d96..0000000 Binary files a/assets/simple-pubsub-server/pubsub-overview.png.dith.gif and /dev/null differ diff --git a/assets/world-clock/hardware.jpg.dith.gif b/assets/world-clock/hardware.jpg.dith.gif deleted file mode 100644 index bcbb428..0000000 Binary files a/assets/world-clock/hardware.jpg.dith.gif and /dev/null differ diff --git a/assets/world-clock/world-clock.jpg.dith.gif b/assets/world-clock/world-clock.jpg.dith.gif deleted file mode 100644 index 69cec9d..0000000 Binary files a/assets/world-clock/world-clock.jpg.dith.gif and /dev/null differ diff --git a/posts/2011-01-13-most-likely-to-succeed-in-year-of-2011.md b/posts/2011-01-13-most-likely-to-succeed-in-year-of-2011.md new file mode 100755 index 0000000..df54f63 --- /dev/null +++ b/posts/2011-01-13-most-likely-to-succeed-in-year-of-2011.md @@ -0,0 +1,26 @@ +--- +Title: Most likely to succeed in the year of 2011 +Description: Most likely to succeed in the year of 2011 +Slug: most-likely-to-succeed-in-year-of-2011 +Listing: true +Created: 2011-01-13 +Tags: [] +--- + +The year of 2010 was definitely the year of Geo-location. The market responded beautifully and lots of very cool services were launched. We all have to thank the mobile market for such extensive adoption. With new generations of mobile phones that are not only buffed with high-tech hardware but are also affordable. We can now manage tasks that were not so long time ago, almost Star Trek’ish. And all this had and has great influence on the destination to which we are going now. + +Reading all this articles about new innovation about new thriving technologies makes me wonder what’s the next step. The future is the mesh, like Lisa Gansky said in her book The Mesh. + +Many still have conservative views on distributed systems. The problems with security of information. Fear of not controlling every aspect of information flow. I am very opened to distributed systems and heterogeneous applications, and I think this is the correct and best way to proceed. + +This year will definitely be about communication platforms. Mobile to mobile. Machine to mobile and vice versa. All the tech is available and ready to put into action. Wireless is today’s new mantra. And the concept of semantic web is now ready for industry. + +Applications and developers now can gain access to new layers of systems and can prepare and build solutions to meet the high quality needs of market. The speed is everything now. + +My vote goes to “Machine to Machine” and “Embedded Systems”! + +- [Machine-to-Machine](http://en.wikipedia.org/wiki/Machine-to-Machine) +- [The ultimate M2M communication protocol](http://www.bitxml.org/) +- [COOS Project (connectivity initiative)](http://www.coosproject.org/maven-site/1.0.0/project-info.html) +- [Community for machine-to-machine](http://m2m.com/index.jspa) +- [Embedded system](http://en.wikipedia.org/wiki/Embedded_system) diff --git a/posts/2012-03-09-led-technology-not-so-eco copy.md b/posts/2012-03-09-led-technology-not-so-eco copy.md deleted file mode 100755 index df54f63..0000000 --- a/posts/2012-03-09-led-technology-not-so-eco copy.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -Title: Most likely to succeed in the year of 2011 -Description: Most likely to succeed in the year of 2011 -Slug: most-likely-to-succeed-in-year-of-2011 -Listing: true -Created: 2011-01-13 -Tags: [] ---- - -The year of 2010 was definitely the year of Geo-location. The market responded beautifully and lots of very cool services were launched. We all have to thank the mobile market for such extensive adoption. With new generations of mobile phones that are not only buffed with high-tech hardware but are also affordable. We can now manage tasks that were not so long time ago, almost Star Trek’ish. And all this had and has great influence on the destination to which we are going now. - -Reading all this articles about new innovation about new thriving technologies makes me wonder what’s the next step. The future is the mesh, like Lisa Gansky said in her book The Mesh. - -Many still have conservative views on distributed systems. The problems with security of information. Fear of not controlling every aspect of information flow. I am very opened to distributed systems and heterogeneous applications, and I think this is the correct and best way to proceed. - -This year will definitely be about communication platforms. Mobile to mobile. Machine to mobile and vice versa. All the tech is available and ready to put into action. Wireless is today’s new mantra. And the concept of semantic web is now ready for industry. - -Applications and developers now can gain access to new layers of systems and can prepare and build solutions to meet the high quality needs of market. The speed is everything now. - -My vote goes to “Machine to Machine” and “Embedded Systems”! - -- [Machine-to-Machine](http://en.wikipedia.org/wiki/Machine-to-Machine) -- [The ultimate M2M communication protocol](http://www.bitxml.org/) -- [COOS Project (connectivity initiative)](http://www.coosproject.org/maven-site/1.0.0/project-info.html) -- [Community for machine-to-machine](http://m2m.com/index.jspa) -- [Embedded system](http://en.wikipedia.org/wiki/Embedded_system) diff --git a/posts/2017-04-21-profiling-python-web-applications-with-visual-tools.md b/posts/2017-04-21-profiling-python-web-applications-with-visual-tools.md index 9a0540b..f2d4190 100644 --- a/posts/2017-04-21-profiling-python-web-applications-with-visual-tools.md +++ b/posts/2017-04-21-profiling-python-web-applications-with-visual-tools.md @@ -18,7 +18,7 @@ Before we begin there are some requirements. We will need to: If you are using MacOS you should check out [Profiling Viewer](http://www.profilingviewer.com/) or [MacCallGrind](http://www.maccallgrind.com/). -![KCachegrind](/assets/python-profiling/kcachegrind.png.dith.gif) +![KCachegrind](/assets/python-profiling/kcachegrind.png) We will be dividing this post into two main categories: @@ -137,7 +137,7 @@ $ pyprof2calltree -i awesome_random_number.prof This file can be opened with visualizing tools listed above. In this case we will be using Profilling Viewer under MacOS. You can open image in new tab. As you can see from this example there is hierarchy of execution order of your code. -![Profilling Viewer](/assets/python-profiling/profiling-viewer.png.dith.gif) +![Profilling Viewer](/assets/python-profiling/profiling-viewer.png) > Make sure you convert output of the cProfile output every time you want to refresh and take a look at your possible optimizations because cProfile updates .prof file every time browser hits the function. @@ -160,7 +160,7 @@ $ snakeviz awesome_random_number.prof # shows visualized profile ``` -![SnakeViz](/assets/python-profiling/snakeviz.png.dith.gif) +![SnakeViz](/assets/python-profiling/snakeviz.png) Reddit user [ccharles](https://www.reddit.com/user/ccharles) suggested a better way for installing pip software by targeting user level instead of using sudo. diff --git a/posts/2017-08-11-simple-iot-application.md b/posts/2017-08-11-simple-iot-application.md index ff8cf9d..0c90f43 100644 --- a/posts/2017-08-11-simple-iot-application.md +++ b/posts/2017-08-11-simple-iot-application.md @@ -150,11 +150,11 @@ To run this simply go to folder containing python file and run ```python webapp. After testing the service with Restlet Client you should be able to view your data in a database file ```data.db```. -![REST settings example](/assets/iot-application/iot-rest-example.png.dith.gif) +![REST settings example](/assets/iot-application/iot-rest-example.png) You can also check the contents of new database file by using desktop client for SQLite → [DB Browser for SQLite](http://sqlitebrowser.org/). -![SQLite database example](/assets/iot-application/iot-sqlite-db.png.dith.gif) +![SQLite database example](/assets/iot-application/iot-sqlite-db.png) Table structure is as simple as it can be. We have ts (timestamp) and value (value from Arduino). As you can see timestamp is generated on API side. If you would happen to have atomic clock on Arduino it would be then better to generate and send timestamp with the value. This would be particularity useful if we would be collecting sensor data at a higher frequency and then sending this data in bulk to API. @@ -471,7 +471,7 @@ If everything goes well you should be seeing new data-points rendered on chart e If you navigate to ```http://0.0.0.0:5000``` you should see rendered chart as shown on picture below. -![Application output](/assets/iot-application/iot-app-output.png.dith.gif) +![Application output](/assets/iot-application/iot-app-output.png) Complete application with all the code is available for [download](/assets/iot-application/simple-iot-application.zip). diff --git a/posts/2018-01-16-using-digitalocean-spaces-object-storage-with-fuse.md b/posts/2018-01-16-using-digitalocean-spaces-object-storage-with-fuse.md index 5293576..9b75ac7 100644 --- a/posts/2018-01-16-using-digitalocean-spaces-object-storage-with-fuse.md +++ b/posts/2018-01-16-using-digitalocean-spaces-object-storage-with-fuse.md @@ -28,13 +28,13 @@ To make this work you will need DigitalOcean account. If you don't have one you Instuctions on how to use SSH keys and how to setup them are available in article [How To Use SSH Keys with DigitalOcean Droplets](https://www.digitalocean.com/community/tutorials/how-to-use-ssh-keys-with-digitalocean-droplets). -![DigitalOcean Droplets](/assets/do-fuse/fuse-droplets.png.dith.gif) +![DigitalOcean Droplets](/assets/do-fuse/fuse-droplets.png) After we created Droplet it's time to create new Space. This is done by clicking on a button [Create](https://cloud.digitalocean.com/spaces/new) (right top corner) and selecting Spaces. Choose pronounceable ```Unique name``` because we will use it in examples below. You can either choose Private or Public, it doesn't matter in our case. And you can always change that in the future. When you have created new Space we should [generate Access key](https://cloud.digitalocean.com/settings/api/tokens). This link will guide to the page when you can generate this key. After you create new one, please save provided Key and Secret because Secret will not be shown again. -![DigitalOcean Spaces](/assets/do-fuse/fuse-spaces.png.dith.gif) +![DigitalOcean Spaces](/assets/do-fuse/fuse-spaces.png) Now that we have new Space and Access key we should SSH into our machine. diff --git a/posts/2019-01-03-encoding-binary-data-into-dna-sequence.md b/posts/2019-01-03-encoding-binary-data-into-dna-sequence.md index 6f6b3d7..fdbdf5b 100644 --- a/posts/2019-01-03-encoding-binary-data-into-dna-sequence.md +++ b/posts/2019-01-03-encoding-binary-data-into-dna-sequence.md @@ -83,7 +83,7 @@ Deoxyribonucleic acid, a self-replicating material which is **present in nearly The nucleotide in DNA consists of a sugar (deoxyribose), one of four bases (cytosine (C), thymine (T), adenine (A), guanine (G)), and a phosphate. Cytosine and thymine are pyrimidine bases, while adenine and guanine are purine bases. The sugar and the base together are called a nucleoside. -![DNA](/assets/dna-sequence/dna-basics.jpg.dith.gif) +![DNA](/assets/dna-sequence/dna-basics.jpg) *DNA (a) forms a double stranded helix, and (b) adenine pairs with thymine and cytosine pairs with guanine. (credit a: modification of work by Jerome Walker, Dennis Myts)* @@ -248,7 +248,7 @@ Then we encode FASTA file from previous operation to encode this data into PNG. After encoding into PNG format this file looks like this. -![Encoded Quote in PNG format](/assets/dna-sequence/quote.png.dith.gif) +![Encoded Quote in PNG format](/assets/dna-sequence/quote.png) The larger the input stream is the larger the PNG file would be. @@ -315,7 +315,7 @@ dd if=<(openssl enc -aes-256-ctr -pass pass:"$(dd if=/dev/urandom bs=128 count= Our freshly generated 1KB file looks something like this (its full of garbage data as intended). -![Sample binary file 1KB](/assets/dna-sequence/sample-binary-file.png.dith.gif) +![Sample binary file 1KB](/assets/dna-sequence/sample-binary-file.png) We create following binary files: - 1KB.bin diff --git a/posts/2019-10-19-using-sentiment-analysis-for-click-bait-detection-in-rss-feeds.md b/posts/2019-10-19-using-sentiment-analysis-for-click-bait-detection-in-rss-feeds.md deleted file mode 100644 index 088b431..0000000 --- a/posts/2019-10-19-using-sentiment-analysis-for-click-bait-detection-in-rss-feeds.md +++ /dev/null @@ -1,88 +0,0 @@ ---- -Title: Using sentiment analysis for click‑bait detection in RSS feeds -Description: Using Python with sentiment analysis to detect if titles in RSS feeds are click-bait -Slug: using-sentiment-analysis-for-click-bait-detection-in-rss-feeds -Listing: true -Created: 2019-10-19 -Tags: [] ---- - -## Initial thoughts - -One of the things that interested me for a while now is if major well established news sites use click bait titles to drive additional traffic to their sites and generate additional impressions. - -Goal is to see how article titles and actual content of article differ from each other and see if titles are click-baited. - -## Preparing and cleaning data - -For this example I opted to just use RSS feed from a new website and decided to go with [The Guardian](https://www.theguardian.com) World news. While this gets us limited data (~40) articles and also description (actual content) is trimmed this really doesn't reflect the actual article contents. - -To get better content I could use web scraping and use RSS as link list and fetch contents directly from website, but for this simple example this will suffice. - -There are couple of requirements we need to install before we continue: - -- `pip3 install feedparser` (parses RSS feed from url) -- `pip3 install vaderSentiment` (does sentiment polarity analysis) -- `pip3 install matplotlib` (plots chart of results) - -So first we need to fetch RSS data and sanitize HTML content from description. - -```python -import re -import feedparser - -feed_url = "https://www.theguardian.com/world/rss" -feed = feedparser.parse(feed_url) - -# sanitize html -for item in feed.entries: - item.description = re.sub('<[^<]+?>', '', item.description) -``` - -## Perform sentiment analysis - -Since we now have cleaned up data in our `feed.entries` object we can start with performing sentiment analysis. - -There are many sentiment analysis libraries available that range from rule-based sentiment analysis up to machine learning supported analysis. To keep things simple I decided to use rule-based analysis library [vaderSentiment](https://github.com/cjhutto/vaderSentiment) from [C.J. Hutto](https://github.com/cjhutto). Really nice library and quite easy to use. - -```python -from vaderSentiment.vaderSentiment import SentimentIntensityAnalyzer -analyser = SentimentIntensityAnalyzer() - -sentiment_results = [] -for item in feed.entries: - sentiment_title = analyser.polarity_scores(item.title) - sentiment_description = analyser.polarity_scores(item.description) - sentiment_results.append([sentiment_title['compound'], sentiment_description['compound']]) -``` - -Now that we have this data in a shape that is compatible with matplotlib we can plot results to see the difference between title and description sentiment of an article. - -```python -import matplotlib.pyplot as plt - -plt.rcParams['figure.figsize'] = (15, 3) -plt.plot(sentiment_results, drawstyle='steps') -plt.title('Sentiment analysis relationship between title and description (Guardian World News)') -plt.legend(['title', 'description']) -plt.show() -``` - -## Results and assets - -1. Because of the small sample size further conclusions are impossible to make. -2. Rule-based approach may not be the best way of doing this. By using deep learning we would be able to get better insights. -3. **Next step would be to** periodically fetch RSS items and store them over a longer period of time and then perform analysis again and use either machine learning or deep learning on top of it. - -![Relationship between title and description](/assets/sentiment-analysis/guardian-sa-title-desc-relationship.png.dith.gif) - -Figure above displays difference between title and description sentiment for specific RSS feed item. 1 means positive and -1 means negative sentiment. - -[» Download Jupyter Notebook](/assets/sentiment-analysis/sentiment-analysis.ipynb) - -## Going further - -- [Twitter Sentiment Analysis by Bryan Schwierzke](https://github.com/bswiss/news_mood) -- [AFINN-based sentiment analysis for Node.js by Andrew Sliwinski](https://github.com/thisandagain/sentiment) -- [Sentiment Analysis with LSTMs in Tensorflow by Adit Deshpande](https://github.com/adeshpande3/LSTM-Sentiment-Analysis) -- [Sentiment analysis on tweets using Naive Bayes, SVM, CNN, LSTM, etc. by Abdul Fatir](https://github.com/abdulfatir/twitter-sentiment-analysis) diff --git a/posts/2019-10-19-using-sentiment-analysis-for-clickbait-detection.md b/posts/2019-10-19-using-sentiment-analysis-for-clickbait-detection.md new file mode 100644 index 0000000..831b490 --- /dev/null +++ b/posts/2019-10-19-using-sentiment-analysis-for-clickbait-detection.md @@ -0,0 +1,88 @@ +--- +Title: Using sentiment analysis for clickbait detection in RSS feeds +Description: Using Python with sentiment analysis to detect if titles in RSS feeds are clickbait +Slug: using-sentiment-analysis-for-clickbait-detection-in-rss-feeds +Listing: true +Created: 2019-10-19 +Tags: [] +--- + +## Initial thoughts + +One of the things that interested me for a while now is if major well established news sites use click bait titles to drive additional traffic to their sites and generate additional impressions. + +Goal is to see how article titles and actual content of article differ from each other and see if titles are clickbaited. + +## Preparing and cleaning data + +For this example I opted to just use RSS feed from a new website and decided to go with [The Guardian](https://www.theguardian.com) World news. While this gets us limited data (~40) articles and also description (actual content) is trimmed this really doesn't reflect the actual article contents. + +To get better content I could use web scraping and use RSS as link list and fetch contents directly from website, but for this simple example this will suffice. + +There are couple of requirements we need to install before we continue: + +- `pip3 install feedparser` (parses RSS feed from url) +- `pip3 install vaderSentiment` (does sentiment polarity analysis) +- `pip3 install matplotlib` (plots chart of results) + +So first we need to fetch RSS data and sanitize HTML content from description. + +```python +import re +import feedparser + +feed_url = "https://www.theguardian.com/world/rss" +feed = feedparser.parse(feed_url) + +# sanitize html +for item in feed.entries: + item.description = re.sub('<[^<]+?>', '', item.description) +``` + +## Perform sentiment analysis + +Since we now have cleaned up data in our `feed.entries` object we can start with performing sentiment analysis. + +There are many sentiment analysis libraries available that range from rule-based sentiment analysis up to machine learning supported analysis. To keep things simple I decided to use rule-based analysis library [vaderSentiment](https://github.com/cjhutto/vaderSentiment) from [C.J. Hutto](https://github.com/cjhutto). Really nice library and quite easy to use. + +```python +from vaderSentiment.vaderSentiment import SentimentIntensityAnalyzer +analyser = SentimentIntensityAnalyzer() + +sentiment_results = [] +for item in feed.entries: + sentiment_title = analyser.polarity_scores(item.title) + sentiment_description = analyser.polarity_scores(item.description) + sentiment_results.append([sentiment_title['compound'], sentiment_description['compound']]) +``` + +Now that we have this data in a shape that is compatible with matplotlib we can plot results to see the difference between title and description sentiment of an article. + +```python +import matplotlib.pyplot as plt + +plt.rcParams['figure.figsize'] = (15, 3) +plt.plot(sentiment_results, drawstyle='steps') +plt.title('Sentiment analysis relationship between title and description (Guardian World News)') +plt.legend(['title', 'description']) +plt.show() +``` + +## Results and assets + +1. Because of the small sample size further conclusions are impossible to make. +2. Rule-based approach may not be the best way of doing this. By using deep learning we would be able to get better insights. +3. **Next step would be to** periodically fetch RSS items and store them over a longer period of time and then perform analysis again and use either machine learning or deep learning on top of it. + +![Relationship between title and description](/assets/sentiment-analysis/guardian-sa-title-desc-relationship.png) + +Figure above displays difference between title and description sentiment for specific RSS feed item. 1 means positive and -1 means negative sentiment. + +[» Download Jupyter Notebook](/assets/sentiment-analysis/sentiment-analysis.ipynb) + +## Going further + +- [Twitter Sentiment Analysis by Bryan Schwierzke](https://github.com/bswiss/news_mood) +- [AFINN-based sentiment analysis for Node.js by Andrew Sliwinski](https://github.com/thisandagain/sentiment) +- [Sentiment Analysis with LSTMs in Tensorflow by Adit Deshpande](https://github.com/adeshpande3/LSTM-Sentiment-Analysis) +- [Sentiment analysis on tweets using Naive Bayes, SVM, CNN, LSTM, etc. by Abdul Fatir](https://github.com/abdulfatir/twitter-sentiment-analysis) diff --git a/posts/2020-03-22-simple-sse-based-pubsub-server.md b/posts/2020-03-22-simple-sse-based-pubsub-server.md index 4db3a57..4256aed 100644 --- a/posts/2020-03-22-simple-sse-based-pubsub-server.md +++ b/posts/2020-03-22-simple-sse-based-pubsub-server.md @@ -23,7 +23,7 @@ Publisher Subscriber model is nothing new and there are many amazing solutions o The easiest way to explain this is with diagram bellow. Basic function is simple. We have subscribers that receive messages, and we have publishers that create and post messages. Similar model is also well know pattern that works on a premise of consumers and producers, and they take similar roles. -![How PubSub works](/assets/simple-pubsub-server/pubsub-overview.png.dith.gif) +![How PubSub works](/assets/simple-pubsub-server/pubsub-overview.png) **These are some naive characteristics we want to achieve:** @@ -49,7 +49,7 @@ Read more about it on [official specification page](https://html.spec.whatwg.org ### Current browser support -![Browser support](../assets/simple-pubsub-server/caniuse.png.dith.gif) +![Browser support](../assets/simple-pubsub-server/caniuse.png) Check [https://caniuse.com/#feat=eventsource](https://caniuse.com/#feat=eventsource) for latest information about browser support. @@ -107,7 +107,7 @@ Google Chrome provides build-in debugging and exploration tool for [Server-Sent > You can debug only client side events that get received and not the server ones. For debugging server events add `console.log` to `server.js` code and print out events. -![Google Chrome Developer Tools EventStream](../assets/simple-pubsub-server/chrome-debugging.png.dith.gif) +![Google Chrome Developer Tools EventStream](../assets/simple-pubsub-server/chrome-debugging.png) ## Server implementation diff --git a/posts/2020-09-06-esp-and-micropython.md b/posts/2020-09-06-esp-and-micropython.md index 730ca7e..a0a3b93 100644 --- a/posts/2020-09-06-esp-and-micropython.md +++ b/posts/2020-09-06-esp-and-micropython.md @@ -25,7 +25,7 @@ A while ago I bought some [ESP8266](https://www.espressif.com/en/products/socs/e For my project, I used [ESP32](https://www.espressif.com/en/products/socs/esp32) but I could easily choose [ESP8266](https://www.espressif.com/en/products/socs/esp8266). This guide contains which tools I use and how I prepared my workspace to code for [ESP8266](https://www.espressif.com/en/products/socs/esp8266). -![ESP8266 and ESP32 boards](/assets/esp8366-micropython/boards.jpg.dith.gif) +![ESP8266 and ESP32 boards](/assets/esp8366-micropython/boards.jpg) This guide covers: - flashing SOC diff --git a/posts/2020-09-08-bind-warning-on-login.md b/posts/2020-09-08-bind-warning-on-login.md index cae781f..ab26b0c 100644 --- a/posts/2020-09-08-bind-warning-on-login.md +++ b/posts/2020-09-08-bind-warning-on-login.md @@ -23,7 +23,7 @@ bind '"\e[Z":menu-complete-backward' I haven't noticed anything wrong with this and all was working fine until I restarted my machine and then I got this error. -![Profile bind error](/assets/profile-bind-error/error.jpg.dith.gif) +![Profile bind error](/assets/profile-bind-error/error.jpg) When I pressed OK, I got into the [Gnome shell](https://wiki.gnome.org/Projects/GnomeShell) and all was working fine, but the error was still bugging me. I started looking for the reason why this is happening and found a solution to this error on [Remote SSH Commands - bash bind warning: line editing not enabled](https://superuser.com/a/892682). diff --git a/posts/2021-01-24-replacing-dropbox-with-s3.md b/posts/2021-01-24-replacing-dropbox-with-s3.md index 55f8923..4a181b5 100644 --- a/posts/2021-01-24-replacing-dropbox-with-s3.md +++ b/posts/2021-01-24-replacing-dropbox-with-s3.md @@ -80,7 +80,7 @@ You can use this script in a combination with [Cron](https://en.wikipedia.org/wi When you start syncing your local stuff with a remote server you can review your items on DigitalOcean. -![Dropbox Spaces](/assets/dropbox-sync/dropbox-spaces.png.dith.gif) +![Dropbox Spaces](/assets/dropbox-sync/dropbox-spaces.png) I have been using this script now for quite some time, and it's working flawlessly. I also uninstalled Dropbox and stopped using it completely. diff --git a/posts/2021-01-25-goaccess.md b/posts/2021-01-25-goaccess.md index e0bda95..7b5ba5c 100644 --- a/posts/2021-01-25-goaccess.md +++ b/posts/2021-01-25-goaccess.md @@ -31,10 +31,10 @@ I found this amazing software [GoAccess](https://goaccess.io/) which provides al GoAccess can be used in two different modes. -![GoAccess Terminal](/assets/goaccess/goaccess-dash-term.png.dith.gif) +![GoAccess Terminal](/assets/goaccess/goaccess-dash-term.png)
Running in a terminal
-![GoAccess HTML](/assets/goaccess/goaccess-dash-html.png.dith.gif) +![GoAccess HTML](/assets/goaccess/goaccess-dash-html.png)
Running in a browser
I, however, need this to run in a browser. So, the second option is the way to go. The Idea is to periodically run cronjob and export this report into a folder that gets then server by Nginx behind a Basic authentication. diff --git a/posts/2021-06-26-simple-world-clock.md b/posts/2021-06-26-simple-world-clock.md index 1e1cd99..29c199a 100644 --- a/posts/2021-06-26-simple-world-clock.md +++ b/posts/2021-06-26-simple-world-clock.md @@ -15,7 +15,7 @@ But I also have a bunch of electronics that I bought through the time, and I am A while ago I bought a small eInk display [Inky pHAT](https://shop.pimoroni.com/products/inky-phat?variant=12549254217811) and I have a bunch of [Raspberry Pi's Zero](https://www.raspberrypi.org/products/raspberry-pi-zero/) lying around that I really need to use. -![Inky pHAT, Raspberry Pi Zero](/assets/world-clock/hardware.jpg.dith.gif) +![Inky pHAT, Raspberry Pi Zero](/assets/world-clock/hardware.jpg) Since the Inky [Inky pHAT](https://shop.pimoroni.com/products/inky-phat?variant=12549254217811) is essentially a HAT, it can easily be added on top of the [Raspberry Pi Zero](https://www.raspberrypi.org/products/raspberry-pi-zero/). @@ -80,7 +80,7 @@ Then we add a cronjob with `crontab -e`. So, we end up with a result like this. -![World Clock](/assets/world-clock/world-clock.jpg.dith.gif) +![World Clock](/assets/world-clock/world-clock.jpg) And for the enclosure that can be 3D printed, but I haven't yet something like this can be used. diff --git a/posts/2021-12-01-debian-based-riced-up-distribution-for-developers.md b/posts/2021-12-01-debian-based-riced-up-distribution-for-developers.md new file mode 100644 index 0000000..55acd61 --- /dev/null +++ b/posts/2021-12-01-debian-based-riced-up-distribution-for-developers.md @@ -0,0 +1,143 @@ +--- +Title: Debian based riced up distribution for Developers and DevOps folks +Description: Debian based riced up distribution for Developers and DevOps folks +Slug: debian-based-riced-up-distribution-for-developers-and-devops-folks +Listing: false +Created: 2021-12-01 +Tags: [] +--- + +I have been using [Ubuntu](https://ubuntu.com/) for quite a longtime now. I have used [Debian](https://www.debian.org/) in the past and [Manjaro](https://manjaro.org/). Also had [Arch](https://archlinux.org/) for some time and even ran [Gentoo](https://www.gentoo.org/) way back. + +What I learned from all this is that I prefer running a bit older versions and having them be stable than run bleeding edge rolling release. For that reason, I stuck with Ubuntu for a couple of years now. I am also at a point in my life where I just don't care what is cool or hip anymore. I just want a stable system that doesn't get in my way. + +During all this, I noticed that these distributions were getting very bloated and a lot of software got included that I usually uninstall on fresh installation. Maybe this is my OCD speaking, but why do I have to give fresh installation min 1 GB of ram out of the box just to have a blank screen in front of me? I get it, there are many things included in the distro to make my life easier. I understand. But at this point I have a feeling that modern Linux distributions are becoming similar to [Node.js project with node_modules](https://devhumor.com/content/uploads/images/August2017/node-modules.jpg). Just a crazy number of packages serving very little or no purpose, just supporting other software. + +I felt I needed a fresh start. To start over with something minimal and clean. Something that would put a little more joy into using a computer again. + +For the first version, I wanted to target the following machines I have at home that I want this thing to work on. + +```yaml +# My main stationary work machine +Resolution: 3840x1080 (Super Ultrawide Monitor 32:9) +CPU: Intel i7-8700 (12) @ 4.600GHz +GPU: AMD ATI Radeon RX 470/480/570/570X/580/580X/590 +Memory: 32020MiB +``` + +```yaml +# Thinkpad x220 for testing things and goofing around +Resolution: 1366x768 +CPU: Intel i5-2520M (4) @ 3.200GHz +GPU: Intel 2nd Generation Core Processor Family +Memory: 15891MiB +``` + +## How should I approach this? + +I knew I wanted to use [minimal Debian netinst ](https://www.debian.org/CD/netinst/) for the base to give myself a head start. No reason to go through changing the installer and also testing all that behemoth of a thing. So, some sort of ricing was the only logical option to get this thing of the grounds somewhat quickly. + + +> **What is ricing anyway?** +> The term “RICE” stands for Race Inspired Cosmetic Enhancement. A group of people (could be one, idk) decided to see if they could tweak their own distros like they/others did their cars. This gave rise to a community of Linux/Unix enthusiasts trying to make their distros look cooler and better than others... For more information, read this article [What in the world is ricing!?](https://pesos.github.io/2020/07/14/what-is-ricing.html). + +I didn't want this to just be a set of config files for theming purpose. I wanted this to include a set of pre-installed tools and services that are being used all the time by a modern developer. Theming is just a tiny part of it. Fonts being applied across the distro and things like that. + +First, I choose terminal installer and left it to load additional components. Avoid using graphical installer in this case. + +![](/assets/dfd-rice/install-00.png) + +After that I selected hostname and created a normal user and set password for that user and root user and choose guided mode for disk partitioning. + +![](/assets/dfd-rice/install-01.png) + +I left it run to install all the things required for the base system and opted out of scanning additional media for use by the package manager. Those will be downloaded from the internet during installation. + +![](/assets/dfd-rice/install-02.png) + + +I opted out of the popularity contest, and **now comes the important part**. Uncheck all the boxes in Software selection and only leave 'standard system utilities'. I also left an SSH server, so I was able to log in to the machine from my main PC. + +![](/assets/dfd-rice/install-03.png) + +At this point, I installed GRUB bootloader on the disk where I installed the system. + +![](/assets/dfd-rice/install-04.png) + +That concluded the installation of base Debian and after restarting the computer I was prompted with the login screen. + +![](/assets/dfd-rice/install-05.png) + +Now that I had the base installation, it was time to choose what software do I want to include in this so-called distribution. I wanted out of the box developer experience, so I had plenty to choose. + +Let's not waste time and go through the list. + +## Desktop environments + +I have been using [Gnome](https://www.gnome.org/) for my whole Linux life. From version 2 forward. It's been quite a ride. I hated version 3 when it came out and replaced version 2. But I got used to it. And now with version 40+ they also made couple of changes which I found both frustrating and presently surprised. + +The amount of vertical space you loose because of the beefy title bars on windows is ridiculous. And then in case of [Tilix](https://gnunn1.github.io/tilix-web/) you also have tabs, and you are 100px deep. Vertical space is one of the most important things for a developer. The more real estate you have, the more code you can have in a viewport. + +But on the other hand, I still love how Gnome feels and looks. I gotta give them that. They really are trying to make Gnome feel unified and modern. + +Regardless of all the nice things Gnome has, I was looking at the tiling window managers for some time, but never had the nerve to actually go with it. But now was the ideal time to give it a go. No guts, no glory kind of a thing. + +One of the requirements for me was easy custom layouts because I use a really strange monitor with aspect ratio of 32:9. So relying on included layouts most of them have is a non-starter. + +What I was doing in Gnome was having windows in a layout like the diagram below. This is my common practice. And if you look at it you can clearly see I was replicating tiling window manager setup in Gnome. + +![](/assets/dfd-rice/layout.png) + + +That made me look into a bunch of tiling window managers and then tested them out. Candidates I was looking at were: + +- [i3](https://i3wm.org/) +- [bspwm](https://github.com/baskerville/bspwm) +- [awesome](https://awesomewm.org/index.html) +- [XMonad](https://xmonad.org/) +- [sway](https://swaywm.org/) +- [Qtile](http://www.qtile.org/) +- [dwm](https://dwm.suckless.org/) + +You can also check article [13 Best Tiling Window Managers for Linux](https://www.tecmint.com/best-tiling-window-managers-for-linux/) I was referencing while testing them out. + +While all of them provided what I needed, I liked i3 the most. What particular caught my eye was the ease to use and tree based layouts which allows flexible layouts. I know others can be set up also to have custom layouts other than spiral, dwindle etc. I think i3 is a good entry-level window manager for somebody like me. + + +## Batteries included + + +```sh +# docker +print_header "Installing Docker" +curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --yes --dearmor -o /usr/share/keyrings/docker-archive-keyring.gpg +echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/docker-archive-keyring.gpg] https://download.docker.com/linux/debian $(lsb_release -cs) stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null +apt update +apt -y install docker-ce docker-ce-cli containerd.io docker-compose + +systemctl start docker +systemctl enable docker +systemctl status docker --no-pager + +/sbin/usermod -aG docker $USERNAME +``` + +### Making bash pretty + +I really like [Oh My Zsh](https://ohmyz.sh/), but I don't like zsh shell. When I used it, I constantly needed to be aware of it and running bash scripts was a pain. So, I was really delighted when I found out that a version for bash existed called [Oh My Bash](https://ohmybash.nntoan.com/). Let's take a look at the recipe for installing it. + +```sh +# ohmybash +print_header "Enabling OhMyBash" +sudo -u $USERNAME sh -c "$(curl -fsSL https://raw.github.com/ohmybash/oh-my-bash/master/tools/install.sh)" & +T1=${!} +wait ${T1} +``` + +Because OhMyBash does `exec bash` at the end, this traps our script inside another shell and our script cannot continue. For that reason, I executed this in background. But that presents a new problem. Because this is executed in background, we lose track of progress naturally. And that strange trick with `T1=${!}` and `wait ${T1}` waits for the background process to finish before continuing to another task in bash script. + +[Multi-Threaded Processing in Bash Scripts](https://www.cloudsavvyit.com/12277/how-to-use-multi-threaded-processing-in-bash-scripts/) + + + + diff --git a/template/_meta.html b/template/_meta.html index a539a6d..93f168a 100755 --- a/template/_meta.html +++ b/template/_meta.html @@ -5,7 +5,7 @@ - + diff --git a/template/_navigation.html b/template/_navigation.html index a4c072d..d484fdd 100755 --- a/template/_navigation.html +++ b/template/_navigation.html @@ -10,6 +10,8 @@ CV + + diff --git a/template/openring-build.html b/template/openring-build.html new file mode 100644 index 0000000..e69de29 diff --git a/template/script.js b/template/script.js index ad98600..4c508ed 100755 --- a/template/script.js +++ b/template/script.js @@ -1,17 +1,17 @@ window.addEventListener('load', () => { // dither image on mouse over replace - document.querySelectorAll('article img').forEach(img => { - const ditheredImage = img.src; - const originalImage = img.src.replace('.dith.gif', ''); + // document.querySelectorAll('article img').forEach(img => { + // const ditheredImage = img.src; + // const originalImage = img.src.replace('.dith.gif', ''); - img.addEventListener('mouseover', evt => { - evt.target.src = originalImage; - }); + // img.addEventListener('mouseover', evt => { + // evt.target.src = originalImage; + // }); - img.addEventListener('mouseout', evt => { - evt.target.src = ditheredImage; - }); - }); + // img.addEventListener('mouseout', evt => { + // evt.target.src = ditheredImage; + // }); + // }); // flip CV image on mouse over const cvImage = document.querySelector('.cv-picture img'); diff --git a/template/style.css b/template/style.css index 972c8f0..aa0be85 100755 --- a/template/style.css +++ b/template/style.css @@ -1,5 +1,5 @@ :root { - --base-document-width: 740px; + --base-document-width: 680px; --base-font-size: 18px; --base-color: #111111; @@ -176,7 +176,7 @@ blockquote p { .post-list li time { display: block; - font-size: 70%; + font-size: 80%; font-weight: 500; line-height: 1.2em; } @@ -300,7 +300,7 @@ article img { position: relative; left: -10%; margin: 40px auto; - border: 1px solid #eee; + /* border: 1px solid #eee; */ } article strong { @@ -349,7 +349,7 @@ audio { article img { max-width: 100%; position: initial; - margin: 50px auto; + margin: 20px auto; } } -- cgit v1.2.3