133 Commits

Author SHA1 Message Date
5c22c6fcee Altered PSR-12 update 2023-05-18 22:28:26 -06:00
70fb0b15d8 Added coding standards 2023-05-18 22:27:59 -06:00
5deac6cf55 Fixed missing enum dependency
Used Taha Amin Ghafuri's (@tahaghafuri ) fork to replace the missing "cedx/enum" package with the "myclabs/php-enum" package
1.0.6
2023-05-18 21:10:14 -06:00
714d079287 owner.php - Typing fix 2023-05-18 21:10:14 -06:00
ea64578fd9 PushEvent - Updated the validateRequest() method
+ Added ability to skip secret key validation, which is useful for newer version of gitea (as its depreciated now)
1.0.5
2021-11-04 20:52:06 -06:00
dbdff87baf Hotfix - Renamed occurences of old method name
+ Replaced instances of `getRawFile()` with `getFileContents()`
1.0.4
2021-11-02 14:47:41 -06:00
785d0b43a2 Fixed errant operator 1.0.3 2021-08-26 12:54:55 -06:00
f468b67335 Repositories - Updated the getRawFile() method
+ Renamed the `getRawFile()` method to `getFileContents`
+ Updated the method to make it use the `/repos/{owner}/{repo}/contents/{filepath}` API route
2020-08-05 22:13:22 -06:00
d37650a882 Amendment - Fixed a bug in the new "getByID" method 2020-04-01 13:05:25 -06:00
e60312fab3 Repositories - Added a new "getById" method
+ Added a new method for retrieving repositories using their ID
2020-03-31 17:19:46 -06:00
cc6bd39f82 Tag Model - Fixed a tag ID related bug
+ Fixed a bug that was causing Acappella to only generate out composer packages for the most recent tag in each repository
2020-03-31 16:13:43 -06:00
027b430adc Model Objects - Fixed bugs caused by numeric strings
+ Made the model objects accept numeric strings instead of being so strict about integer values
1.0.2
2020-03-31 14:00:52 -06:00
27972b95c7 Corrected spelling mistake in project name 1.0.1 2020-03-03 15:17:24 -07:00
6a9a55dafc Removed the .vscode folder from the repository 1.0.0 2020-03-03 14:57:15 -07:00
739d27a1db Updated composer.json and README file
+ Changed the name of the project to "sugar-cube-client"
+ Updated the composer.json file
+ Updated the README file
2020-03-03 14:53:43 -07:00
8004781e62 Updated the .gitignore and license files 2020-03-03 14:47:31 -07:00
362ed05780 Removed several unneeded files and folders 2020-03-03 14:46:59 -07:00
28aa608b9b Updated the license text 2020-03-03 11:12:29 -07:00
e127129d3a Ammendment - Fixed an error in the last commit 2020-03-01 17:08:37 -07:00
ba39e61094 PushEvents - Fixed two errors
+ Fixed "array_map() expects parameter 1 to be a valid callback" error
+ Fixed "Argument 1 passed to Gitea\PushEvent::setCommits() must be of the type array, null given"
2020-03-01 17:06:32 -07:00
784f76b767 Removed a few unneeded "use" statements from files 2020-03-01 17:05:16 -07:00
75d80d8b6e PushEvent - Fixed a "Too few arguments" error
+ Fixed a "Too few arguments" error that was produced by code in the `fromJson()` method
2020-03-01 16:39:22 -07:00
b1a5ff58e1 Fixed errors caused by "self" in interfaces
+ Fixed an error that was caused by the presence of "self" in type hinting inside interfaces
2020-02-28 19:25:31 -07:00
a4402e78a6 PushEvent - Updated the model + Added extra method
+ Updated the model to make it align with the ApiModel Interface
+ Added a `validateRequest()` method for validating push event requests
2020-02-28 18:58:17 -07:00
5227b4b995 Client - Added push event "secret key" storage 2020-02-28 18:55:47 -07:00
7cf7d59a54 Small updates to Interfaces and abstract classes
+ Removed extra spaces from method definitions
2020-02-28 18:53:39 -07:00
cdbee13e11 Updated RequestChanable Interface and Trait
+ Fixed an error that was caused by the use of the "self" type-hint in a trait
+ Added more  type-hints to the `setCaller()` method
2020-02-28 12:01:46 -07:00
52244adb34 composer.json - Removed autoloader optimization 2020-02-28 11:12:21 -07:00
239b6b4748 Updated RequestChainable interface and trait
+ Added a new `findOrRequestRepository()` method
2020-02-26 22:52:21 -07:00
f5c7ed4962 Updated RequestChainable Interface and Trait
+ Added a new searchRequestChain()  method that will climb up the request chain searching for an object of a certain class
+ Added some test code for the new method in the TestRun.php file
2020-02-26 22:34:36 -07:00
70f978847e Large changes to inter-object interfaces + More
+ Created a new core interface (called RequestChainable) and applied it to most of the objects using a trait
+ Altered the `__construct()` and `fromJson()` methods of all model classes by replacing the second parameter ($apiRequester) with a $caller parameter
+ Altered the  `__construct()` method of all requester classes to make them accept $client by reference instead of by value
+ Altered the  `__construct()` method of all requester classes by replacing the second parameter ($authToken) with a $caller parameter
+ Changed the name of several methods and properties
+ Altered several docblocks
2020-02-26 20:23:06 -07:00
57bf45938f Updated the composer.json file with my information 2020-02-26 20:14:47 -07:00
a6f2ee8c8a Client - Added a static create() method 2020-02-25 21:38:09 -07:00
0594dce6d0 Updated the .editorconfig to make it more specific 2020-02-25 12:32:37 -07:00
36b06aef96 Updated the TestRun file
+ Added several more tests
2020-02-25 12:32:07 -07:00
128b8f4d4a Updated the Repositories API requester
+ Updated use statements and class names
+ Added a `getByName()` method for getting a repository using its owner and name
+ Added a `getRawFile()` method for getting the contents of a file from a repository
+ Added a `downloadArchive()` method for downloading an archive for a repository
2020-02-25 12:31:30 -07:00
baf886674f Updated the Repository model class
+ Updated namespaces and class names
+ Updated several methods to make this conform to the ApiModelInterface
+ Added a new tags() method for retreiving all tags for a repository
+ Added a new branches() method for retreiving all branches for a repository
+ Added a new archive() method for downloading an archive for the repository
2020-02-25 12:29:16 -07:00
505c4d1750 Client - Added connections for new API requesters
+ Added a connection to the new Tags API requester
+ Added a connection to the new Branches API requester
2020-02-25 12:24:11 -07:00
df8af0b028 Ammendment - Added a missed model 2020-02-25 12:22:34 -07:00
50fb2110ea Made four models conform to the ApiModelInterface
+ Updated the methods and class definitions of several models to make them conform to the new ApiModelInterface
2020-02-25 12:21:51 -07:00
b9320163b9 Organizations - Updated use statements...
+ Updated use statements and class names
2020-02-25 12:18:24 -07:00
712cb7f5ea ApiCollectionInterface - Updated use statments...
+ Updated uses statements and class names
2020-02-25 12:14:48 -07:00
64315d7145 Created two new API requester
+ Created a new Tags API requester to allow us to make tag related API requests
+ Created a new Branches API requester to allow us to make branch related API requests
2020-02-25 12:13:05 -07:00
5153ea84a9 Created three new model classes
+ Created a Branch model class for storing branch data
+ Created a Tag model class for storing tag data
+ Created an Owner model class for storing owner data for branches
2020-02-25 12:11:31 -07:00
9b1e0fe523 Created an interface and abstract class for models
+ Created an interface and abstract class for models to extend
2020-02-25 12:09:21 -07:00
3f5527ee8c Renamed Interfaces and Abstract classes
+ Renamed several classes to make it easier to understand what they are for
2020-02-25 12:07:47 -07:00
5df01f7b54 Moved the ApiCollectionInterface class
+ Move the ApiCollectionInterface class into a new "Collections/Interfaces/" folder
2020-02-20 13:26:42 -07:00
dcd2d8bdf3 Corrected namespaces + Chnaged tab size to 4
+ Went through all the Model classes and updated their namespaces to match their parent folder name
+ Changed tab sizes to 4 spaces instead of 2 (in all php files)
2020-02-20 13:21:18 -07:00
b17224ce39 Refactored and reorganized
+ Created new a new interface and abstract class for Api classes that support the all() method
+ Refactored the Repositories Api class
+ Moved the abstract classes into an "Abstracts" folder
+ Moved Api Interfaces into an "Interfaces" folder
+ Corrected namespaces
2020-02-20 13:08:41 -07:00
1bf0c070f8 Huge number of updates, too tired to list them all
+ Added a bunch of API handler classes that will use the already created models
+ Created a new Client class that will connect to new API handler classes
+ Created new collection classes
2020-02-19 22:10:59 -07:00