37 Commits
Author SHA1 Message Date
Jam Balaya e754d2c70d refactor!: Pass the Projects v2 item body types by value and rename them to ...Request (#4609)
BREAKING CHANGE: `AddProjectItemOptions` and `UpdateProjectItemOptions` are renamed to `AddProjectItemRequest` and `UpdateProjectItemRequest` and passed by value; `AddProjectItemRequest.Type` is no longer a pointer; `UpdateProjectItemOptions.Archived` is removed.
2026-10-12 15:38:37 -04:00
Jam Balaya 227adb57e0 feat: Add remaining Projects v2 endpoints (#4319) 2026-07-18 09:08:55 -04:00
Oleksandr Redko 3f47638460 refactor: Fix parameters in method endpoints (#4300) 2026-06-17 07:19:34 -04:00
Oleksandr Redko d472d0844b fix: Use value receiver for MarshalJSON (#4211) 2026-05-14 17:16:06 -04:00
Steve Hipwell 9fbf4bef19 feat!: Refactor request context (#4151)
BREAKING CHANGE: All internal calls now provide `Context` via the `Request` itself.
2026-04-24 14:45:31 -04:00
Oleksandr Redko 33cf038ac1 docs: Add apiVersion to GitHub API link (#4147) 2026-04-11 10:47:17 -04:00
Glenn Lewis a2063a76fb chore: Remove unnecessary use of new and &SomeStruct{} and add new extraneousnew custom linter (#4106) 2026-03-18 17:12:53 -04:00
Glenn Lewis 71958fb26f fix!: Pass url struct tags by value instead of by reference (#3991)
BREAKING CHANGE: Many `*Options` structs now pass `omitempty` URL struct fields by value instead of by reference.
2026-02-11 14:07:37 -05:00
Tom Elliott e10040dccd fix!: Add support for missing attributes in ProjectsV2 API (#3888) 2025-12-19 15:19:25 -05:00
Jonathan 8657c38bfe fix!: Fix field selection and bugs in ProjectsV2 GET endpoints (#3809)
BREAKING CHANGE: `UpdateProjectItemOptions.Field` is now `[]*ProjectV2FieldUpdate`.
2025-11-11 21:27:35 -05:00
Jonathan 2b239f2dc6 feat!: Add support for project items CRUD and project fields read operations (#3793) 2025-11-03 07:07:06 -05:00
JoannaaKL 590596afd7 Add ProjectsService (#3718) 2025-10-14 08:02:55 -04:00
Glenn Lewis 550ecbe014 feat!: Remove Project (classic) support (#3380)
BREAKING CHANGE: All support for "Project (classic)" is removed and `Project` responses are replaced by `ProjectV2` (renamed from `ProjectsV2`).

Fixes: #3367.
2024-12-11 08:44:55 -05:00
WillAbides a54bc7da1d Use metadata to reconcile go-github with GitHub's OpenAPI descriptions (#2919) 2023-11-03 10:26:59 -04:00
Glenn Lewis 7a7a7f0943 Update URLs (#2373)
Fixes: #2360.
2022-05-24 08:43:48 -04:00
Dariusz Porowski b9139050d6 Change ProjectOptions (Public to Private) and Project struct fields (#2111)
Fixes: #2110
2021-12-03 09:43:23 -05:00
Glenn Lewis a64f3a6d08 Update URLs (#1659) 2020-12-02 10:39:08 -05:00
Glenn Lewis 159b448168 Switch to new GitHub v3 API Documentation website (#1621) 2020-09-01 18:30:47 -04:00
Glenn Lewis 0683ca03b4 Update URLs (#1558) 2020-06-24 19:27:03 -04:00
kadern0 69231319df Change opt param to opts (#1417)
Fixes #1415.
2020-02-09 20:01:54 -05:00
Naoki Ainoya 4c1ec01570 Fix GetProjectCard argument name (#1239) 2019-07-25 08:15:19 -04:00
Palash Nigam dcd9d6d5ca Add support for Preview organization projects (#1082)
Fixes #884.
2018-12-28 10:20:52 -05:00
Lovro Mažgon 651e77e2c6 Add fields to ProjectCard struct (#1072)
Fixes #1071.
2018-12-17 21:34:20 -05:00
Antoine e16f49dbde Add 'PullRequest' as possible value for ProjectCardOptions (#1051) 2018-11-15 08:38:05 -05:00
Radek Simko d8bee75667 projects: Add missing fields to struct (#969)
Helps #884.
2018-08-13 08:20:17 -04:00
Shagun Khemka 29a3681d05 Remove custom media type for global node IDs (#925)
Fixes #919.
2018-08-10 11:23:19 -04:00
Sanket Payghan e1be32f26e Project card archiving (#953)
Fixes #941.
2018-07-23 11:29:27 -04:00
Anubha Kushwaha 630efeb435 Add NodeID to various endpoints (#836)
Helps #814.
2018-02-23 13:38:07 -08:00
Kshitij Saraogi e48060a28f Migrate IDs to int64 type (#816)
A helper function "Int64" is also implemented to assist the migration of
unit tests.

Refer #597.
2018-01-25 10:59:44 -08:00
Eli Uriegas 0f6d3ce15e Add ProjectOptions.State field. (#746)
State is an optional parameter when updating projects. It gives
the ability to open/close projects via UpdateProject method.

GitHub API docs: https://developer.github.com/v3/projects/#update-a-project
2017-10-12 23:05:41 -04:00
Aravind fe4b6036cb Removed Inconsistency in documentation for ProjectCardOptions(#696) (#700)
Inconsistent documentation was found in file github/projects.go
Edited the doc line to match corresponding Github docs.

Fixes #696.
2017-08-17 15:12:17 -07:00
Francesc Gil 00874eae3f Add missing fields to ProjectCard struct. (#668)
Add missing fields to ProjectCard

Fixes #667.
2017-07-11 09:04:06 -07:00
Dmitri Shuralyov 23d6cb9cac Add support for context package to all endpoints. (#529)
This is a large breaking API change. It is unavoidable and necessary
to resolve #526. This breaking change is part of bump to libraryVersion 3.

It adds ctx context.Context as first parameter to all endpoint methods,
including Do.

Updating for this API change should be easy and the compiler will help
catch instances that need to be updated. For example:

	main.go:193: not enough arguments in call to gh.Activity.MarkRepositoryNotificationsRead
		have (string, string, time.Time)
		want (context.Context, string, string, time.Time)
	...

You should pass the available context as first parameter. If your code
does not have context.Context available and you want to maintain previous
normal behavior, use context.Background(). Don't pass nil context; use
context.TODO() instead if you wish to delay figuring out the best context
to use. Then you can address the TODO at a later time.

Refer to documentation of package context at https://godoc.org/context
for more information.

This commit also changes ./tests/fields to use context.Background()
instead of deprecated oauth2.NoContext.

Resolves #526.
2017-02-20 16:05:42 -05:00
Nick Spragg 30a21ee1a3 Return nil error explicitly when there is no error. (#546)
Helps #536.
Follows #542.
2017-02-13 17:27:33 -05:00
Dmitri Shuralyov 8dc18ba2c1 Fix lint issues with projectID parameter name.
Go style suggests that acronyms, including "ID", should have a consistent case.

> This rule also applies to "ID" when it is short for "identifier," so write
> "appID" instead of "appId".

Source: https://github.com/golang/go/wiki/CodeReviewComments#initialisms

This change fixes the following lint issues:

	github/projects.go:119:46: method parameter projectId should be projectID
	github/projects.go:176:47: method parameter projectId should be projectID

Updates #467.
Closes #498.

Change-Id: I53c5bd5ac59cad1b4ae955c8384ff7b25a20b278
2016-12-21 10:08:07 -08:00
griffin_stewie 5c5ff1dada remove leading slash
reasons
- unify with others
- constructing url does not work when in GitHub Enterprise environment
2016-12-08 23:02:15 +09:00
Lucas Alcantara 905f04725b changed to point to new Projects API
Created new service ProjectsService and removed methods in repos_projects that belong to ProjectsService.

Minor tweaks by @gmlewis following review.

Fixes #461.
Closes #467.

Change-Id: I8b85ff6e716151b505c843c905534bd5fe8257ae
2016-11-09 16:18:48 -08:00