LoginSignup
2
1

More than 5 years have passed since last update.

Githubの自分のリポジトリを一覧する

Posted at

Githubのリポジトリが増えてくると何してたのかわからなくなるので一覧ななにかを用意する。
Descriptionに要素技術とかをちまちま入力していきたい。

  • リポジトリ名
  • GithubでのURL
  • Description

を一覧する

作成物

作成物はここ

内容

  1. curlでAPIからjson取得
  2. 取得結果をパース

プログラム

import json

with open('repos1') as f:
    jsons = json.loads(f.read().strip())
    for j in jsons:
        print(j['full_name'])
        print(j['html_url'])
        print(j['description'])
        print("\n")

#!/bin/bash

curl -u ${1} "https://api.github.com/user/repos?per_page=100&page=1" > repos1
python a.py > result.txt
rm -f repos1
open result.txt
rm -f result.txt

結果(抜粋)

.
.
.

modeverv/filedb
https://github.com/modeverv/filedb
None
.
.
.
modeverv/first-vue.js
https://github.com/modeverv/first-vue.js
None
.
.
.

参考というかそのまま

2
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
1