diff --git a/.forestry/settings.yml b/.forestry/settings.yml
new file mode 100644
index 0000000..ed61c77
--- /dev/null
+++ b/.forestry/settings.yml
@@ -0,0 +1,27 @@
+---
+new_page_extension: md
+auto_deploy: false
+admin_path:
+webhook_url:
+sections:
+- type: jekyll-pages
+ label: Pages
+ create: all
+- type: jekyll-posts
+ label: Posts
+ create: all
+upload_dir: uploads
+public_path: "/uploads"
+front_matter_path: ''
+use_front_matter_path: false
+file_template: ":filename:"
+build:
+ preview_env:
+ - JEKYLL_ENV=staging
+ preview_output_directory: _site
+ install_dependencies_command: bundle install --path vendor/bundle
+ preview_docker_image: forestryio/ruby:2.6
+ mount_path: "/srv"
+ working_dir: "/srv"
+ instant_preview_command: bundle exec jekyll serve --drafts --unpublished --future
+ --port 8080 --host 0.0.0.0 -d _site
diff --git a/Gemfile b/Gemfile
index b6416b7..060fa08 100644
--- a/Gemfile
+++ b/Gemfile
@@ -19,5 +19,6 @@ group :jekyll_plugins do
gem 'rouge'
end
+# Jekyll admin
gem 'jekyll-admin', group: :jekyll_plugins
diff --git a/README.md b/README.md
index a1ff701..97601f4 100644
--- a/README.md
+++ b/README.md
@@ -1,23 +1,4 @@
-# Mediumish - Jekyll Theme
+# adiatma.github.io
-[Live Demo](https://wowthemesnet.github.io/mediumish-theme-jekyll/) | [Download](https://github.com/wowthemesnet/mediumish-theme-jekyll/archive/master.zip) | [Documentation](https://bootstrapstarter.com/bootstrap-templates/template-mediumish-bootstrap-jekyll/) | [Buy me a coffee](https://www.wowthemes.net/donate/)
+This blogs built with [jekyll](https://jekyllrb.com/), [jekyll-admin](https://github.com/jekyll/jekyll-admin), and using [mediumish](https://www.wowthemes.net/mediumish-free-jekyll-template/) theme.
-
-
-
-### Copyright
-
-Copyright (C) 2019 Sal, https://www.wowthemes.net
-
-**Mediumish for Jekyll** is designed and developed by [Sal](https://www.wowthemes.net) and it is *free* under MIT license.
-
-
-
-### Contribute
-
-1. [Fork the repo](https://github.com/wowthemesnet/mediumish-theme-jekyll).
-2. Clone a copy of your fork on your local
-3. Create a branch off of master and give it a meaningful name (e.g. my-new-mediumish-feature).
-4. Make necessary changes, commit, push and open a pull request on GitHub.
-
-Thank you!
diff --git a/_config.yml b/_config.yml
index 23e5ac5..963d74f 100644
--- a/_config.yml
+++ b/_config.yml
@@ -1,72 +1,54 @@
-# Site
-name: "Mediumish"
-title: "Mediumish"
-description: "Jekyll template, Medium styled, free for bloggers."
-logo: 'assets/images/logo.png'
-favicon: 'assets/images/logo.png'
+name: Adiatma Kamarudin
+title: Adiatma Kamarudin
+description: Just personal blogs.
+logo: assets/images/logo.png
+favicon: assets/images/logo.png
baseurl: ''
-google_analytics: ''
-disqus: 'demowebsite'
-mailchimp-list: 'https://wowthemes.us11.list-manage.com/subscribe/post?u=8aeb20a530e124561927d3bd8&id=8c3d2d214b'
-include: ["_pages"]
-permalink: /:title/
-
-# Authors
+google_analytics: '"UA-143014045-1"'
+disqus: adiatma9024
+include:
+ - _pages
+permalink: '/:title/'
authors:
- sal:
- name: Sal
- display_name: Sal
- gravatar: e56154546cf4be74e393c62d1ae9f9d4
- email: wowthemesnet@gmail.com
- web: https://www.wowthemes.net
- twitter: https://twitter.com/wowthemesnet
- description: "Author of Mediumish, a Bootstrap Medium styled template available for WordPress, HTML, Ghost and Jekyll. You are currently previewing Jekyll template demo."
- john:
- name: John
- display_name: John
- avatar: 'assets/images/avatar.png'
- gravatar: b1cc14991db7a456fcd761680bbc8f81
- email: wowthemesnet@gmail.com
- web: https://www.wowthemes.net
- twitter: https://twitter.com/wowthemesnet
- description: "This is the author box. Write a short description of the author here. You are currently previewing Mediumish demo, a Jekyll template compatible with Github pages."
-
-# Plugins
+ adiatma:
+ name: Adiatma Kamarudin
+ display_name: adiatma
+ email: adiatma9024@gmail.com
+ twitter: https://twitter.com/adiatma__
+ description: "Software Engineer, Opensource Enthusiasm, and Blogger"
+ web: "https://adiatma.github.io"
+ gravatar: 4a2a99c8bd08b234fda70219c575c53a
plugins:
- jekyll-paginate
- jekyll-sitemap
- jekyll-feed
- jekyll-seo-tag
- jekyll-archives
-
-# Archives
jekyll-archives:
enabled:
- categories
layout: archive
permalinks:
category: '/category/:name/'
-
-# Pagination
paginate: 6
-paginate_path: /page:num/
-
-# Other
+paginate_path: '/page:num/'
markdown: kramdown
-
kramdown:
input: GFM
syntax_highlighter: rouge
syntax_highlighter_opts:
block:
line_numbers: true
-
-# Adsense (change to "enabled" to activate, also your client id and ad slot. Create a new ad unit from your Adsense account to get the slot.)
-adsense: "disabled"
-adsense-data-ad-client: "ca-pub-3412143450191416"
-adsense-data-ad-slot: "1363087678"
-
-# Lazy Images ("enabled" or "disabled")
-lazyimages: "disabled"
-
-exclude: [changelog.md, LICENSE.txt, README.md, Gemfile, Gemfile.lock]
+adsense: enabled
+adsense-data-ad-client: "ca-pub-3949943425882481"
+adsense-data-ad-slot: ''
+lazyimages: disabled
+exclude:
+ - changelog.md
+ - LICENSE.txt
+ - README.md
+ - Gemfile
+ - Gemfile.lock
+jekyll_admin:
+ hidden_links:
+ - datafiles
diff --git a/_layouts/default.html b/_layouts/default.html
index 337b917..a5f83a7 100644
--- a/_layouts/default.html
+++ b/_layouts/default.html
@@ -76,19 +76,15 @@
This website is built with Jekyll and Mediumish template for Jekyll. It's for demonstration purposes, no real content can be found. Mediumish template for Jekyll is compatible with Github pages, in fact even this demo is created with Github Pages and hosted with Github.
- -
Please, read the docs here.
- -Head over to our Github repository!
- -Thank you for your support! Your donation helps me to maintain and improve Mediumish .
- -Buy me a coffee Documentation - -
+
+Setelah selesai sekarang coba jalankan lagi perintah `jekyll build` kemudian `jekyll serve` untuk menjalankan server, maka konten kalian akan tampil di halaman utama, okey sampai disini kalian sudah berhasil membuat blog dengan jekyll, terimakasih dan sampai jumpa ditulisan berikutnya.
\ No newline at end of file
diff --git a/_posts/2019-12-08-how-to-deploy-golang-app-in-heroku.md b/_posts/2019-12-08-how-to-deploy-golang-app-in-heroku.md
new file mode 100644
index 0000000..cccfe3a
--- /dev/null
+++ b/_posts/2019-12-08-how-to-deploy-golang-app-in-heroku.md
@@ -0,0 +1,98 @@
+---
+title: How to deploy golang app in heroku
+layout: post
+image: assets/images/heroku-yml.png
+author: adiatma
+categories: golang
+---
+
+Heroku is a platform as a service (Paas) that enable you to deploy and building web apps and save to the cloud. Heroku support any languages or framework like NodeJS, Golang, Ruby, PHP, Python, Scala, and Clojure.
+
+You can be using heroku with premium and free features. please check this [link](https://www.heroku.com/pricing) to compare it.
+
+Okay, today I'm trying to show you, about how to deploy web build with golang to heroku, before start, please make sure you have an account in heroku, if not please [register](https://signup.heroku.com/) before.
+
+## Lets get started
+
+First step create directory with name `deploy-golang-app-in-heroku` and initialize with go module `go mod init github.com/
+
+Okey finish, please see the example [repo](https://github.com/adiatma/deploy-golang-app-in-heroku) and [demo](https://deploy-golang-app-in-heroku.herokuapp.com/) for this tutorial.
+
+Thanks.
\ No newline at end of file
diff --git a/_posts/2019-12-08-learn-modules-in-rust.md b/_posts/2019-12-08-learn-modules-in-rust.md
new file mode 100644
index 0000000..8a69578
--- /dev/null
+++ b/_posts/2019-12-08-learn-modules-in-rust.md
@@ -0,0 +1,93 @@
+---
+title: Learn Modules in Rust
+layout: post
+author: adiatma
+categories: rust
+image: assets/images/hero.png
+---
+
+Rust provides a module system that can be used, you can manage your module system in rust with visibility (public/private) between them.
+
+By default, the items in a module in rust have private visibility, and you have a `pub` keyword to change the visibility module to `public`.
+
+Okay, let's try the example, if you have installed rust in your computer, please create new project with command `cargo new example-rust-module` into your terminal.
+
+```rust
+// ./src/main.rs
+
+// to create module in rust you just add keyword mod before statement.
+mod example_module {
+ // can't be accessing from outher, and just work in this current scope.
+ fn private_function(name: String) -> String {
+ format!("Hay {}", name)
+ }
+
+ // with pub keyword this function can be access public.
+ pub fn public_function(name: String) {
+ println!("{}", private_function(name))
+ }
+}
+
+fn main() {
+ // Call the example_module
+ example_module::public_function(String::from("Adiatma")) // output: Hey Adiatma
+}
+```
+
+Okay, let's create a new file with the name `another_module.rs`.
+
+```rust
+// ./src/another_module.rs
+
+mod hello_module {
+ pub fn hello_func(name: String) {
+ println!("{}", name)
+ }
+}
+```
+
+And call the module in `./src/main.rs`.
+
+```rust
+// ./src/main.rs
+
+mod another_module;
+
+fn main() {
+ another_module::hello_module::hello_func("Adiatma".to_string()); // output: Adiatma
+}
+```
+
+How if you want to create a new directory, let's say `mod_dir`. and create a new module in `mod_dir`, to doing it you need to create a file `lib.rs` in root directory and publish them in `lib.rs` file, below the example for more detail.
+
+```rust
+// ./src/lib.rs
+
+pub mod mod_dir;
+```
+
+And then, in `mod_dir` you just create the file with name `mod.rs`.
+
+```rust
+// ./mod_dir/mod.rs
+
+pub fn hey(name: String) {
+ println!("{}", name)
+}
+```
+
+Okay, let's call the module in `./src/main.rs`.
+
+```rust
+// please add the extern crate keyword and suitable with your project name. example `example_rust_module`.
+extern crate example_rust_module;
+
+// add use keyword to call mod `mod_dir`
+use example_rust_module::mod_dir;
+
+fn main() {
+ mod_dir::hey("Adiatma".to_string()); // output: Adiatma
+}
+```
+
+Okay, we finish to learning module check this out the [repo](https://github.com/adiatma/example-rust-module) to read the source code, and if you are curious to learn more about the module in rust please go to [https://doc.rust-lang.org/rust-by-example/mod.html](https://doc.rust-lang.org/rust-by-example/mod.html).
\ No newline at end of file
diff --git a/_posts/2019-12-08-setup-cors-origin-in-golang.md b/_posts/2019-12-08-setup-cors-origin-in-golang.md
new file mode 100644
index 0000000..a2f396e
--- /dev/null
+++ b/_posts/2019-12-08-setup-cors-origin-in-golang.md
@@ -0,0 +1,64 @@
+---
+title: Setup CORS Origin in Golang
+layout: post
+author: adiatma
+categories: golang
+image: assets/images/cors.png
+---
+
+According to [MDN](https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS) Cors Origin Resource Sharing (CORS) is a mechanism that uses additional HTTP headers to tell browsers to give a web application running at one origin, access to selected resources from different origin.
+
+CORS like a permissions access for communications HTTP in browsers, okay example you have a domain `http://frontend.com` and you request in javascript code to access `https://backend-api.com/` with using `fetch` or `axios` and getting data from server, and to able access from other origin you need to enable cors in `https://backend-api.com/`.
+
+Okay, to enable CORS in golang we need to add some code in header response, below the example to using `net/http`.
+
+```go
+package main
+
+import (
+ "net/http"
+)
+
+func main() {
+ http.HandleFunc("/", func(w http.ResposeWriter, r *http.Request) {
+ // this keyword ("*") to allow all origin to access this endpoint
+ w.Header().Set("Access-Control-Allow-Origin", "*")
+ })
+}
+```
+
+If using [gin-gonic](https://github.com/gin-gonic/gin) library please consider to using [gin-contrib](https://github.com/gin-contrib/cors) to enable cors.
+
+```go
+package main
+
+import (
+ "time"
+
+ "github.com/gin-contrib/cors"
+ "github.com/gin-gonic/gin"
+)
+
+func main() {
+ router := gin.Default()
+ // CORS for https://foo.com and https://github.com origins, allowing:
+ // - PUT and PATCH methods
+ // - Origin header
+ // - Credentials share
+ // - Preflight requests cached for 12 hours
+ router.Use(cors.New(cors.Config{
+ AllowOrigins: []string{"https://foo.com"},
+ AllowMethods: []string{"PUT", "PATCH"},
+ AllowHeaders: []string{"Origin"},
+ ExposeHeaders: []string{"Content-Length"},
+ AllowCredentials: true,
+ AllowOriginFunc: func(origin string) bool {
+ return origin == "https://github.com"
+ },
+ MaxAge: 12 * time.Hour,
+ }))
+ router.Run()
+}
+```
+
+Okay, that is a short tutorial on how to enable CORS in golang.
\ No newline at end of file
diff --git a/assets/images/1.jpg b/assets/images/1.jpg
deleted file mode 100644
index bb467b5..0000000
Binary files a/assets/images/1.jpg and /dev/null differ
diff --git a/assets/images/10.jpg b/assets/images/10.jpg
deleted file mode 100644
index 8cb6363..0000000
Binary files a/assets/images/10.jpg and /dev/null differ
diff --git a/assets/images/11.jpg b/assets/images/11.jpg
deleted file mode 100644
index ca980bb..0000000
Binary files a/assets/images/11.jpg and /dev/null differ
diff --git a/assets/images/12.jpg b/assets/images/12.jpg
deleted file mode 100644
index ac2cfde..0000000
Binary files a/assets/images/12.jpg and /dev/null differ
diff --git a/assets/images/13.jpg b/assets/images/13.jpg
deleted file mode 100644
index 67d1a01..0000000
Binary files a/assets/images/13.jpg and /dev/null differ
diff --git a/assets/images/14.jpg b/assets/images/14.jpg
deleted file mode 100644
index 9562bb8..0000000
Binary files a/assets/images/14.jpg and /dev/null differ
diff --git a/assets/images/15.jpg b/assets/images/15.jpg
deleted file mode 100644
index dd781e4..0000000
Binary files a/assets/images/15.jpg and /dev/null differ
diff --git a/assets/images/16.jpg b/assets/images/16.jpg
deleted file mode 100644
index d580611..0000000
Binary files a/assets/images/16.jpg and /dev/null differ
diff --git a/assets/images/17.jpg b/assets/images/17.jpg
deleted file mode 100644
index 04c7c6d..0000000
Binary files a/assets/images/17.jpg and /dev/null differ
diff --git a/assets/images/2.jpg b/assets/images/2.jpg
deleted file mode 100644
index 6b66d8c..0000000
Binary files a/assets/images/2.jpg and /dev/null differ
diff --git a/assets/images/3.jpg b/assets/images/3.jpg
deleted file mode 100644
index c06f079..0000000
Binary files a/assets/images/3.jpg and /dev/null differ
diff --git a/assets/images/4.jpg b/assets/images/4.jpg
deleted file mode 100644
index 33f2a87..0000000
Binary files a/assets/images/4.jpg and /dev/null differ
diff --git a/assets/images/5.jpg b/assets/images/5.jpg
deleted file mode 100644
index d746d18..0000000
Binary files a/assets/images/5.jpg and /dev/null differ
diff --git a/assets/images/6.jpg b/assets/images/6.jpg
deleted file mode 100644
index 8624ff0..0000000
Binary files a/assets/images/6.jpg and /dev/null differ
diff --git a/assets/images/7.jpg b/assets/images/7.jpg
deleted file mode 100644
index 177abc1..0000000
Binary files a/assets/images/7.jpg and /dev/null differ
diff --git a/assets/images/8.jpg b/assets/images/8.jpg
deleted file mode 100644
index 23b9222..0000000
Binary files a/assets/images/8.jpg and /dev/null differ
diff --git a/assets/images/9.jpg b/assets/images/9.jpg
deleted file mode 100644
index fcc872c..0000000
Binary files a/assets/images/9.jpg and /dev/null differ
diff --git a/assets/images/avatar.png b/assets/images/avatar.png
index 719801d..f32ff5d 100644
Binary files a/assets/images/avatar.png and b/assets/images/avatar.png differ
diff --git a/assets/images/code-html.png b/assets/images/code-html.png
new file mode 100644
index 0000000..24b3761
Binary files /dev/null and b/assets/images/code-html.png differ
diff --git a/assets/images/config-var.png b/assets/images/config-var.png
new file mode 100644
index 0000000..f56ee44
Binary files /dev/null and b/assets/images/config-var.png differ
diff --git a/assets/images/cors.png b/assets/images/cors.png
new file mode 100644
index 0000000..4a10a50
Binary files /dev/null and b/assets/images/cors.png differ
diff --git a/assets/images/hero.png b/assets/images/hero.png
new file mode 100644
index 0000000..3a883d5
Binary files /dev/null and b/assets/images/hero.png differ
diff --git a/assets/images/heroku-yml.png b/assets/images/heroku-yml.png
new file mode 100644
index 0000000..4443268
Binary files /dev/null and b/assets/images/heroku-yml.png differ
diff --git a/assets/images/jekyll.png b/assets/images/jekyll.png
new file mode 100644
index 0000000..f32ff5d
Binary files /dev/null and b/assets/images/jekyll.png differ
diff --git a/assets/images/mediumish-jekyll-template.png b/assets/images/mediumish-jekyll-template.png
deleted file mode 100644
index 7994927..0000000
Binary files a/assets/images/mediumish-jekyll-template.png and /dev/null differ
diff --git a/assets/images/webpack.png b/assets/images/webpack.png
new file mode 100644
index 0000000..9d8702b
Binary files /dev/null and b/assets/images/webpack.png differ
diff --git a/renovate.json b/renovate.json
new file mode 100644
index 0000000..f45d8f1
--- /dev/null
+++ b/renovate.json
@@ -0,0 +1,5 @@
+{
+ "extends": [
+ "config:base"
+ ]
+}