Skip to content

Instantly share code, notes, and snippets.

@zaz600
zaz600 / .zshrc
Created February 20, 2019 19:40
oh-my-zsh powerlevel9k theme config
POWERLEVEL9K_MODE='nerdfont-complete'
ZSH_THEME="powerlevel9k/powerlevel9k"
POWERLEVEL9K_SHORTEN_DIR_LENGTH=1
POWERLEVEL9K_SHORTEN_DELIMITER=""
POWERLEVEL9K_SHORTEN_STRATEGY="truncate_from_right"
POWERLEVEL9K_VCS_GIT_ICON=''
POWERLEVEL9K_VCS_GIT_GITHUB_ICON=''
POWERLEVEL9K_VCS_GIT_GITLAB_ICON=''
POWERLEVEL9K_VCS_GIT_BITBUCKET_ICON=''
POWERLEVEL9K_PROMPT_ON_NEWLINE=true
@zaz600
zaz600 / fizzbuzz.py
Created August 16, 2017 13:58
FizzPuzz perl-style
t,f,b,s,j,p=3,"zFzi","zuzB",sorted,"".join,5;y,z=2,0;list(map(print,[next(filter(lambda i:isinstance(i,str),((i%t,i%p).count(z)!=y or j(s(f))+j(s(b)),i%t or j(s(f)),i%p or j(s(b)),str(i)))) for i in range(1,y*p**y)]))

Keybase proof

I hereby claim:

  • I am zaz600 on github.
  • I am zaz600 (https://keybase.io/zaz600) on keybase.
  • I have a public key ASCR4-dXLx4WAwKtnt7blRY1gp28e8r_9EOXnsEUDAOyWwo

To claim this, I am signing this object:

@zaz600
zaz600 / mdserver.go
Created August 9, 2015 05:11
mdserver
package main
import (
"fmt"
"github.com/bmizerany/pat"
"github.com/russross/blackfriday"
"html/template"
"io/ioutil"
"log"
"net/http"
package main
import (
"encoding/json"
"io/ioutil"
"log"
"math/rand"
"os"
"path/filepath"
"strings"
package main
import (
"encoding/json"
"io/ioutil"
"log"
"math/rand"
"os"
"path/filepath"
"strings"
package main
import (
"encoding/json"
"io/ioutil"
"log"
"os"
"strings"
"time"
)
#Пример файла конфигурации
#Файл в формате YAML поэтому ОТСТУПЫ, ЗНАКИ ТИРЕ (-), ДВОЕТОЧИЯ очень важны
#Для отступов НЕ ИСПОЛЬЗОВАТЬ ТАБУЛЯТОРЫ
#Включить просмотр статистики по HTTP
enable_http: true
#адрес:порт на котором будет доступна статистика
listen: 0.0.0.0:8899
package main
import (
"encoding/json"
"io/ioutil"
"log"
"os"
)
type Config struct {
// web_check.go
package main
import (
"flag"
"fmt"
"net/http"
"os"
"time"
)