A tool for generating template Markdown file for https://github.com/adolphlwq/translate
Clone or download
Latest commit 668c85d Jan 13, 2019
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
cmd update to year 2019 Jan 13, 2019
vendor remove pkgs from vendor Jul 6, 2017
.gitignore remove pkgs from vendor Jul 6, 2017
LICENSE Initial commit Feb 26, 2017
Makefile 0.0.1 Feb 26, 2017
README.md update README of tt Mar 9, 2017
main.go optimize Feb 27, 2017

README.md

tt

Go Report Card

A tool for generating template Markdown file for translate

Usage

install

If you have installed Golang

go install github.com/adolphlwq/tt

else

wget https://github.com/adolphlwq/tt/releases/download/0.2/tt
sudo chmod +x tt
sudo mv tt /usr/local/bin

Usage

  • see version

    translate git:(master) tt version 
    tt version: 0.1
    go version: go1.7.4
    os/arch:    linux/amd64
    
  • new a template post with default arguments

    translate git:(master) tt new
    file "00-example.md" created successfully on "/home/geek/workspace/githubwp/translate/2017"!
    
  • new a template post with customed arguments

    ➜  translate git:(master) ✗ tt new -f adolphlwq-tt -n 10 -y 2017 -t "dive into python"
    file "10-adolphlwq-tt.md" created successfully on "/home/geek/workspace/githubwp/translate/2017"!
    ➜  translate git:(master) ✗ cat 2017/10-adolphlwq-tt.md 
    # dive into python
    
    ## 说明
    - [原文链接]()
    - [翻译:@adolphlwq](https://github.com/adolphlwq)
    - [项目地址](https://github.com/adolphlwq/translate)
    - [tt](https://github.com/adolphlwq/tt):自动生成翻译模板
    - 用时:
    - <a rel="license" href="http://creativecommons.org/licenses/by-nc/4.0/"><img alt="知识共享许可协议" style="border-width:0" src="https://i.creativecommons.org/l/by-nc/4.0/80x15.png" /></a>
    

Options

  • new a post
    create a new template file.
    
    Usage:
    tt new [flags]
    
    Flags:
    -f, --file-name string   file name of your post (default "example")
    -n, --number string      number of your post (default "00")
    -t, --title string       title of your post (default "example")
    -y, --year string        year of directory contains posts (default "2017")
    
  • list issue (defalut adolphlwq/translate)
    Usage:
    tt issue [flags]
    
    Flags:
    -r, --repo string    name of your repo. (default "translate")
    -s, --state string   state of issue to list. (default "open")
    -u, --user string    short name of your github account. (default "adolphlwq")
    

TODOs

  • new: new a post.
  • version: show version info.
  • issue: list issue.