Skip to content

inabajunmr/treview

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

84 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

treview

codecov CircleCI Total alerts

Viewer for GitHub Trending.

Feature

  • shows only today's newcomer repository.(You never see same project everyday!)
  • define default langage that you want to see.
  • GUI for macos

GUI

treview

Install

Download from GUI for macos.

CLI

treview

Install

$ go get github.com/inabajunmr/treview

Usage

$ treview -h
Usage:
  treview is cli viewer for GitHub Trending. [flags]
  treview [command]

Available Commands:
  config      Setting for default langage configration.
  help        Help about any command

Flags:
  -f, --filter string   all or new (default "new")
  -h, --help            help for treview
  -l, --lang string     filter by lang
  -s, --span string     trending span (default "Today")

Use "treview [command] --help" for more information about a command.

Config

If you have file ~/.treview/.config, you can set default lang by treview. You can set config by treview config command too.

treview

Example

If you have following config, treview show only Golang and JavaScript repositories by treview command (without lang flag).

lang:  [go, javascript]

If you want to find all langage, you set all as lang flag.

Appendix (Using as GitHub Trending API for Golang)

GoDoc

Sample

package main

import (
	"fmt"
	"github.com/inabajunmr/treview/github/trending"
)

func main() {
	span := trending.GetSpanByString("today")

	repos, err := trending.FindTrending(l, span)
	if err != nil {
		println(err)
		os.Exit(1)
	}

	for _, repo := range repos {
		fmt.Println("------------------------")
		repo.Print()
	}
}