%T: print type of variable
Create a slice:
| import os | |
| import sys | |
| import pyvips | |
| options = { | |
| 'Q': 75, | |
| 'quant_table': 3, | |
| 'interlace': True, | |
| 'strip': True, | |
| 'optimize_coding': True, |
| {{ $repo := .Get "repo" }} | |
| {{ $detail := getJSON "https://api.github.com/repos/" $repo }} | |
| <article class="shortcode-card"> | |
| <a href="https://github.com/{{ $repo }}" target="_blank" rel="noopener"> | |
| <header> | |
| <img alt="{{ $repo }}" src="https://opengraph.githubassets.com/1/{{ $repo }}" /> | |
| </header> | |
| <div class="shortcode-card-content"> | |
| <h2>{{ .Get "repo" }}</h2> | |
| {{ with $detail }} |
| """ | |
| Sync dockerhub images to ghcr.io or other registry | |
| Usage: | |
| 1. create tag list file `tags.txt` that syncing to ghcr.io | |
| ``` | |
| git tag > tags.txt |
| Vue.js 14 hrs 16 mins ███████████▎░░░░░░░░░ 53.9% | |
| JavaScript 6 hrs 38 mins █████▎░░░░░░░░░░░░░░░ 25.1% | |
| Other 2 hrs 35 mins ██░░░░░░░░░░░░░░░░░░░ 9.8% | |
| Go 1 hr 42 mins █▎░░░░░░░░░░░░░░░░░░░ 6.4% | |
| Git 41 mins ▌░░░░░░░░░░░░░░░░░░░░ 2.6% |
| package main | |
| import ( | |
| "fmt" | |
| "io/ioutil" | |
| "log" | |
| "os" | |
| "regexp" | |
| "sort" | |
| ) |
| #cVim-link-container, .cVim-link-hint, #cVim-command-bar, #cVim-command-bar-mode, #cVim-command-bar-input, #cVim-command-bar-search-results, .cVim-completion-item, .cVim-completion-item .cVim-full, .cVim-completion-item .cVim-left, .cVim-completion-item .cVim-right, #cVim-hud, #cVim-status-bar { | |
| font-family: Helvetica, Helvetica Neue, Neue, sans-serif, monospace, Arial; | |
| font-size: 12pt !important; | |
| -webkit-font-smoothing: antialiased !important; | |
| } | |
| #cVim-link-container { | |
| position: absolute; | |
| pointer-events: none; | |
| width: 100%; left: 0; |
| #!/bin/bash | |
| if [ -z "$1" ] ; then | |
| echo "$(basename "$0") kernel-ver" | |
| exit 1 | |
| fi | |
| PACKAGES=(`dkms status | grep "$1" | awk -F ', ' '{ print $1"/"$2 }'`) |
| from collections import Counter | |
| num = "135481963636" | |
| n = Counter(num) | |
| for key, freq in n.most_common(): | |
| print("{0}: {1}".format(key, freq)) |
| #!/bin/sh | |
| ############ | |
| # require: | |
| # - ffmpeg | |
| # - faad | |
| # - sox | |
| ############ | |
| aac="audio.aac" |