{%- macro back_to(url='/') -%}
  • {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}} {%- if url == '/' -%} {{- '' -}} {%- else -%} ..{{- '' -}} {%- endif -%}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
  • {{- '' -}} {%- endmacro -%} {%- macro archives(archives, max=0, with_back=true, skip_tags=false) -%} {%- if with_back -%} {{- box::back_to() -}} {%- endif -%} {%- for archive in archives -%} {%- if max > 0 and loop.index > max -%} {%- break -%} {%- endif -%} {%- set_global skip = false -%} {%- if skip_tags -%} {%- for skip_tag in skip_tags -%} {%- for tag in archive.tags -%} {%- if skip_tag == tag.title -%} {%- set_global skip = true -%} {%- break -%} {%- endif -%} {%- endfor -%} {%- if skip -%} {%- break -%} {%- endif -%} {%- endfor -%} {%- endif -%} {%- if skip -%} {%- continue -%} {%- endif -%}
  • {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}} {%- if archive.sticky > 0 -%} {{- ' ' -}} {%- endif -%} {{ archive.title }}{{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- archive.summary | truncate(length=20, end='') -}}{{- ' ' -}} {%- for category in archive.categories -%} {{ category.title }}{{- ' ' -}} {%- endfor -%} {%- for tag in archive.tags -%} {{ tag.title }}{{- ' ' -}} {%- endfor -%} {%- if archive.url is starting_with("/archives/") and archive.short -%} #{{ archive.short }}{{- '' -}} {%- endif -%}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- archive.created | date(format="%Y-%m-%d") -}}
    {{- '' -}}
  • {{- '' -}} {%- endfor -%} {%- endmacro -%} {%- macro terms(terms, max=0) -%} {{- box::back_to() -}} {%- for term in terms -%} {%- if max > 0 and loop.index > max -%} {%- break -%} {%- endif -%}
  • {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{ term.title }}{{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- term.archives | length }} items
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {%- set first_archive = term.archives | first -%} {{- first_archive.created | date(format="%Y-%m-%d") -}}
    {{- '' -}}
  • {{- '' -}} {%- endfor -%} {%- endmacro -%} {%- macro archives_head() -%}
    {{- '' -}}
    {{- '' -}} {{- '' -}} {{- theme_ctx.avatar | safe -}} {{- '' -}} {{- ' ' -}} {{ site.author }} committed{{- ' ' -}} {{ site.tagline }}{{- ' ' -}} on {{ now() | date(format="%e %b") }}{{- ' ' -}} ...{{- '' -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- ' ' -}} {{- '' -}} {%- if categories | length == 1 -%} {{- categories[0].archives | length -}} {%- elif tags | length == 1 -%} {{- tags[0].archives | length -}} {%- else -%} {{- archives | length -}} {%- endif -%} {{- ' ' -}} commits{{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}} {{ categories | length }} {{- '' -}} branches{{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}} {{ tags | length }} {{- '' -}} tags{{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {%- endmacro -%} {%- macro archive_head(archive) -%}
    {{- '' -}}
    {{- '' -}} {%- set lines = archive.content | split(pat="\n") | length -%} {{- lines - 1 }} lines{{- ' ' -}} {{- ' ' -}} {%- set words = archive.content | length -%} {{- words * 2 | filesizeformat -}}
    {{- '' -}}
    {{- '' -}} First commit on{{- ' ' -}} {{- '' -}} {{- archive.created | date(format="%e %b %Y") | trim -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}} {%- endmacro -%} {%- macro tweets(archives, max=0) -%} {%- for archive in archives -%} {%- if max > 0 and loop.index > max -%} {%- break -%} {%- endif -%}
  • {{- '' -}}
    {{- '' -}} {{- theme_ctx.avatar | safe -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}} {{- theme_ctx.avatar | safe -}} {{- '' -}} {%- if archive.title -%} {{- '' -}} {{- archive.title -}} {{- '' -}} {%- endif -%} {{- '' -}} {{- archive.created | date(format="%Y-%m-%d") -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}} #{{ archive.short -}} {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- archive.summary | safe -}}{{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
  • {{- '' -}} {%- if archive.sticky > 0 -%}
  • {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}} {{- theme_ctx.avatar | safe -}} {{- '' -}} {{- site.author }} pinned this tweet.{{- '' -}}
    {{- '' -}}
    {{- '' -}}
    {{- '' -}}
  • {{- '' -}} {%- endif -%} {%- endfor -%} {%- endmacro -%} {%- macro activities(activities, max=0, skip_tags=false) -%} {%- set_global count = 0 -%} {%- set_global is_breaked = false -%} {%- for acti in activities -%} {%- if is_breaked -%} {%- break -%} {%- endif -%} {%- for key, archives in acti -%} {%- if key == 'Pinned' -%} {%- continue -%} {%- endif -%}
    {{- '' -}}
    {{- '' -}}
    {{- key -}}
    {{- '' -}}
    {{- '' -}} {{- '' -}}
    {{- '' -}} {%- endfor -%} {%- endfor -%} {%- endmacro -%}