KarimAziev / gh-repo

Create and manage gh repositories in emacs.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

About

This library provides interactive Emacs commands for interacting with GitHub repositories using the GitHub API.

Key features:

  • Creating new repositories
  • Viewing repositories as a rich tree structure
  • Viewing repositories files
  • Listing user repositories
  • Cloning repositories
  • Deleting repositories
  • Viewing repositories as a rich tree structure
  • Searching for repositories with advanced filtering
  • A transient menu is available to access all the key features.

    ./gh-repo.gif

Table of Contents

Requirements

NameVersion
Emacs29.1
request0.3.2
transient0.4.1
ghub3.6.0
ivy0.14.0

Installation

With use-package and straight.el

(use-package gh-repo
  :straight (gh-repo
             :repo "KarimAziev/gh-repo"
             :type git
             :host github)
  :commands (gh-repo-menu)
  :config
  (setq gh-repo-ghub-auth-info '("YOUR_GITHUB_USERNAME" . gh-repo)))

Manual installation

Download the source code and put it wherever you like, e.g. into ~/.emacs.d/gh-repo/

git clone https://github.com/KarimAziev/gh-repo.git ~/.emacs.d/gh-repo/

Add the downloaded directory to the load path:

(add-to-list 'load-path "~/.emacs.d/gh-repo/")
(require 'gh-repo)

Auth

gh-repo manages authentication through customizable variable gh-repo-ghub-auth-info:

This a cons cell, which car is a string containing your GitHub username and cdr is either a string containing the OAuth token or a symbol indicating where to fetch the OAuth token.

For example, if your github username is YOUR_GITHUB_USERNAME is should be:

(setq gh-repo-ghub-auth-info '("YOUR_GITHUB_USERNAME" . gh-repo))

Next, add an entry to your auth-sources:

machine api.github.com login YOUR-GITHUB-USERNAME^gh-repo password YOUR-GITHUB-TOKEN

You can add this entry to your ~/.authinfo.gpg file (recommended for secure, encrypted storage) or ~/.authinfo (see variable auth-sources).

Usage

This library offers several interactive commands to work with GitHub repositories.

A transient menu is available to access all the key features. To open the transient menu, type:

M-x gh-repo-menu

About

Create and manage gh repositories in emacs.

License:GNU General Public License v3.0


Languages

Language:Emacs Lisp 100.0%