- {% assign pg_year = page.date | date: '%Y' %}
- {% assign pg_month = page.date | date: '%m' %}
-
- {% assign postsByYear = site.posts | group_by_exp:"post", "post.date | date: '%Y'" %}
- {% for year in postsByYear %}
-
+
+
+
+
+{% assign cur_year = site.date | date: '%Y' %}
+{% assign last_p_year = site.date | date: '%Y' %}
+{% for post in site.posts %}
+ {% unless post.next %}
- {% if pg_year == year.name %}
-
- {% assign postsByMonth = year.items | group_by_exp:"post", "post.date | date: '%m'" %}
- {% assign postsByMonthSorted = postsByMonth | sort: 'name' | reverse %}
- {% for month in postsByMonthSorted %}
- -
- {% for post in month.items limit:1 %}
-
-
- {{ post.date | date: '%B %Y' }}
-
- {% endfor %}
+ {% assign post_year = post.date | date: '%Y' %}
+ {% if post_year == cur_year %}
+
Bu yılın arşivi
+ {% else %}
+ {% if post_year != last_p_year %}
+
+
+{{ post.date | date: '%Y' }}
+ {% assign last_p_year = post.date | date: '%Y' %}
- {% if pg_month == month.name %}
-
- {% endif %}
-
- {% endfor %}
-
- {% endif %}
- {% endfor %}
-
-
+ {% endif %}
+ {% endif %}
+ {% endunless %}
+ {% assign months = "Ocak|Şubat|Mart|Nisan|Mayıs|Haziran|Temmuz|Ağustos|Eylül|Ekim|Kasım|Aralık" | split: "|" %}
+ {% assign m = post.date | date: "%-m" | minus: 1 %}
+ {% assign dd = post.date | date: "%d" %}
+ {% assign mm = months[m] %}
+ {% assign yy = post.date | date: "%Y" %}
+