Skip to content

Commit

Permalink
Add GitLab support
Browse files Browse the repository at this point in the history
  • Loading branch information
k-bx committed May 17, 2020
1 parent 40b090d commit d5a39af
Show file tree
Hide file tree
Showing 6 changed files with 260 additions and 136 deletions.
3 changes: 3 additions & 0 deletions Changelog.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# 0.2.0

- Add GitLab support
10 changes: 8 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# github-agent
# GitHub (and GitLab) Agent

Many of us enjoy working on a project where issues are detailed,
well-written and kept up to date. There's just one problem with that:
editing issues is not fun.

With GitHub Agent, you can sync your issues as text files to some
With Git(Hub/Lab) Agent, you can sync your issues as text files to some
local folder, in fact a git repo, and use your favorite editor for
editing, and run a periodic "sync" command doing the least surprising
job at syncing the issues.
Expand Down Expand Up @@ -37,3 +37,9 @@ Usage:
`<number>.md` in some local git repo path, then commit the changes
- `github-agent sync-out` -- for every modified issue, check if it
wasn't modified on server, and edit it in the repo, commit changes

## Misc

TODO:

- gitlab: don't list all the issues in the `getIssueInfo` every time (add appropriate API in gitlab-haskell)
24 changes: 16 additions & 8 deletions config.dhall.example
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
{ repos =
[ { repo_owner_name = "exampleowner"
, repo_name = "reponame"
, repo_data_dir = "/path/to/datadir-git-repo"
, repo_auth = "oauthtoken-see-https://github.com/settings/tokens"
}
]
}
let RepoSource = < Github | Gitlab >
in { repos =
[ { repo_owner_name = "exampleowner"
, repo_name = "reponame"
, repo_source = RepoSource.Github
, repo_data_dir = "/path/to/reponame-issues"
, repo_auth = "oauthtoken-see-https://github.com/settings/tokens"
}
, { repo_owner_name = "exampleowner"
, repo_name = "reponame2"
, repo_source = RepoSource.Gitlab
, repo_data_dir = "/path/to/reponame2-issues"
, repo_auth = "oauthtoken-see-https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html"
}
]
}
5 changes: 4 additions & 1 deletion package.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: github-agent
version: 0.1.1
version: 0.2.0
#synopsis:
#description:
homepage: https://github.com/k-bx/github-agent#readme
Expand All @@ -18,12 +18,15 @@ dependencies:
- directory
- dhall
- github
- gitlab-haskell
- optparse-applicative
- safe
- rio
- string-class
- text
- time
- typed-process
- vector

default-extensions:
- AutoDeriveTypeable
Expand Down
Loading

0 comments on commit d5a39af

Please sign in to comment.