Commit Graph

250 Commits

Author SHA1 Message Date
Josh Bialkowski
d349137ea5 fix usage of newIdentityRaw 2020-02-17 13:13:25 -08:00
Josh Bialkowski
bbd31adbff Fix jira bridge config didn't save credentials or store URL metadata 2020-02-17 12:43:42 -08:00
Michael Muré
01b0a931f7
jira: fix a nil context 2020-02-15 16:12:21 +01:00
Michael Muré
5c230cb81e
jira: rework to use the credential system + adapt to refactors 2020-02-15 16:01:15 +01:00
Michael Muré
0bb9ed9b0e
Merge remote-tracking branch 'origin/master' into cheshirekow-jira 2020-02-15 15:51:16 +01:00
Michael Muré
e231b6e839
bridges: pass the context to Init for when a client build process needs it 2020-02-15 15:46:36 +01:00
Michael Muré
cfa005889a
Merge remote-tracking branch 'origin/master' into cheshirekow-jira 2020-02-15 13:54:51 +01:00
Michael Muré
87b97ca4b2
bridges: more refactor and cleanup 2020-02-15 13:45:14 +01:00
Michael Muré
432a816dde
Merge remote-tracking branch 'origin/master' into cheshirekow-jira 2020-02-15 03:07:45 +01:00
Michael Muré
fe3d5c95e4
bridges: massive refactor
- automatic flag validation and warning
- generalized prompt
- cleanups
2020-02-15 02:55:19 +01:00
Michael Muré
e9aff2a2a1
Merge remote-tracking branch 'origin/master' into cheshirekow-jira 2020-02-14 22:56:59 +01:00
Michael Muré
34083de0df auth: refactor and introduce Login and LoginPassword, salt IDs 2020-02-12 23:37:57 +01:00
Michael Muré
bd7b50bc86
github/gitlab: many fixes and improvments at the config step 2020-02-10 01:22:01 +01:00
Michael Muré
b2ca506210
jira: admittedly biased go styling 2020-02-09 21:08:47 +01:00
Michael Muré
2792c85b21
jira: use the new generalized prompts 2020-02-09 20:52:19 +01:00
Michael Muré
b3d3612393
Merge remote-tracking branch 'origin/master' into cheshirekow-jira 2020-02-09 20:23:38 +01:00
Michael Muré
9b1aaa032d
bridge: fix 2 uncatched errors 2020-02-08 22:08:35 +01:00
Michael Muré
bef35d4c67
bridge: hopefully fix tests 2020-02-08 22:05:13 +01:00
Michael Muré
a335725cc5
bridge: fix wrong error used 2020-02-08 22:04:51 +01:00
Michael Muré
8773929f96
github: make sure to have a name 2020-02-08 22:04:25 +01:00
Michael Muré
2e7ac569ad
fix tests ? 2020-02-08 17:35:35 +01:00
Michael Muré
646fd681ff
it compiles \o/ 2020-02-08 17:19:57 +01:00
Michael Muré
f515b9a129
gitlab also compile 2020-02-08 17:19:57 +01:00
Michael Muré
74e9114410
more more wip 2020-02-08 17:19:57 +01:00
Michael Muré
8da522d97a
wip 2020-02-08 17:18:30 +01:00
Michael Muré
b950c2580d
more wip 2020-02-08 17:18:30 +01:00
Michael Muré
ae2f942ef9
more wip 2020-02-08 17:18:28 +01:00
Michael Muré
26f0152384
WIP 2020-02-08 17:18:28 +01:00
Michael Muré
db893494bb
input: better reusable prompt functions 2020-02-08 17:18:27 +01:00
Michael Muré
ee48aef489
github: warning when the comment to be edited is missing instead of failing
fix #286
2020-01-04 13:11:29 +01:00
Josh Bialkowski
a785bcdad6
codereview #6: don't fail one warning
* presence of an error in the import event doesn't indicate failure
2020-01-04 13:04:21 +01:00
Josh Bialkowski
f15206e7b1
* Fix git config reader can't read values with spaces
* Add NewImportWarning for things that aren't exactly errors.
  Use this for unhandled changelog events.
* Add NewExportWarning for things that aren't exactly errors.
  Use this for un-exportable status changes.
2020-01-04 13:04:15 +01:00
Michael Muré
86b114ae7e
gitlab: proper token generation URL with custom base URL 2020-01-03 13:53:59 +01:00
Michael Muré
d2ed6747e5
gitlab: fix edit not being pushed with baseUrl
fix #284
2020-01-03 13:52:03 +01:00
Michael Muré
1bcba473fb
Merge pull request #280 from MichaelMure/bridge-gitlab
bridge/gitlab: add base url configuration
2019-12-27 12:12:01 +01:00
Amine
c769348c75
bridge/gitlab/config.go printing typo
Co-Authored-By: Michael Muré <batolettre@gmail.com>
2019-12-27 03:29:53 +01:00
amine
5cffb5d114 bridge/gitlab: add missing baseUrl prompt and options
bridge/gitlab: fix api calls with self hosted Gitlab instances
2019-12-26 20:16:18 +01:00
Michael Muré
864d3ed335 bridge: allow to configure and pull without having set a user first
- init() only the importer or exporter as required
- assign a "default user" user Id to credentials at creation if no user has been set
- "bridge auth": also display the user
- "bridge auth show": adapt to a potential "default user" user Id
- "bridge configure": allow to run without a user set
- "bridge pull": allow to run without a user set
- "user adopt": replace "default user" by the actual user id when run
2019-12-25 23:25:39 +01:00
Josh Bialkowski
dca85b309a repair after rebase 2019-12-18 12:18:47 -08:00
Josh Bialkowski
3384d1b26b codereview #6: don't fail one warning
* presence of an error in the import event doesn't indicate failure
2019-12-18 07:42:16 -08:00
Josh Bialkowski
4e64c834e2 codereview #5: reverse-map and ImportWarning
* Fix git config reader can't read values with spaces
* Add bug-id-revmap config option for the reverse map, and use this
  in the importer
* Add NewImportWarning for things that aren't exactly errors.
  Use this for unhandled changelog events.
* Add NewExportWarning for things that aren't exactly errors.
  Use this for un-exportable status changes.
* Strip newlines from titles on import
2019-12-18 07:42:16 -08:00
Josh Bialkowski
98bd372e60 codereview #4: fixes from testing
* don't prefix imported title's with jira ID
* fix import new comment due to wrong variable name
* fix double import of comment edition due to improper err check
* fix JIRA cloud paginated changelog has a different JSON
  field then the embedded changelog in the JIRA server issue
  object
* fix splitting label strings yielded an empty string as a label
  value
2019-12-18 07:42:16 -08:00
Josh Bialkowski
a59aaebc7e codreview #3: two credential types, more fixes
* Support both token and session credential types
* use getTimeDervedID in export.go
* keyOrigin -> core.KeyOrigin
* fix one indentation
* remove project key from operation metadata
* fix missing credentials codepath if not using sidecar
2019-12-18 07:42:16 -08:00
Josh Bialkowski
cd889572f7 codereview #2: some cleanup, correct use of nothing-events
* return error, don't panic
* skipping status export is an error
* use switch in config.go
* move PromptPassword to input
* move client construction into getIdentityClient
* use non-pointer context throughout client since it is an interface
* remove some TODOs
* don't emit multiple nothing-events, just one per bug only if nothing
  happened.
* rename EditBody to EditCreateComment
* add configuration notes about additional values
* store bug id map in a dictionary in the config
* some fixes from testing
2019-12-18 07:42:16 -08:00
Josh Bialkowski
7657a38ff2 codereview #1: clean lint from golangcibot 2019-12-18 07:42:16 -08:00
Josh Bialkowski
eff830bdcb Implement jira bridge 2019-12-18 07:42:13 -08:00
amine
f6b4830c0b bridge/gitlab: support self-hosted GitLab instance 2019-12-10 21:05:55 +01:00
Michael Muré
f1ed857cbd
Merge pull request #271 from MichaelMure/bridge-credentials
bridge: huge refactor to accept multiple kind of credentials
2019-12-10 00:42:23 +01:00
amine
58c0e5aac9 auth: Correctly cast configs[configKeyKind] 2019-12-09 17:16:44 +01:00
Michael Muré
4c6d33e48e
type the CredentialKind values
Co-Authored-By: Amine <hilalyamine@gmail.com>
2019-12-09 16:43:30 +01:00