| Age | Commit message (Collapse) | Author |
|
Added option to change mirror, tmp, staging directoryfrom the user
interface of the pkgman library. Added TRY and TRY_IFNOT macros for
better code readability.
|
|
Feature and refactor commits do not require all subsystems to be used
as a prefix for the git title <e.g. build:>, instead they just need to
list all affected subsystems within the commit description.
|
|
Creates an default option to heap-init string view to be used by
complex operation where memory needs to be fine-grained.
|
|
cookbook_recipe_run() now returns the return code of fork() to manage
success state.
|
|
Seperates cryptographic verification from pkgman_upstream_integrity_download
to its own function for better code structure, and to create space for future
cryptographic functions.
|
|
Added url structures, cookbook, archive management to automate
the installation process of packages. Refactored main logic from
main.c to pkgman.c for cleaner seperation of concerns and future
library integration of pkgman to other projects.
|
|
Add more error codes to prepare for future improvements. Add FORKERR,
INTEGRITYERR, URLPATHERR, URLINITERR.
|
|
Enables all warnings, treats warnings as errors and stylistic
improvements are treated as warnings. This is enabled to increase
code quality.
|
|
Creates a write_opts argument in net_send_request() where you can
specify WRITE_OPT_MEMORY or WRITE_OPT_FILE. Modifies existing calls.
|
|
First parameter renamed to argc, and second renamed to argv to fit
the general C-style entry function convention.
|
|
The install command frees all allocated memory at the cleanup
section, and iterates over the linked list to cleanup struct pair's
key.buf and value.buf.
|
|
Linked list now implements FREE, ADD, functionalities. This
modification allows for easier use of linked list and less bugs.
The linked list functions now also have header and implementation
macros to allow for external use of linked list functions in other
translation units.
|
|
Removed the redundant if-else block and malloc() from write_callback()
since realloc() can handle null ptr.
|
|
To create a system-wide utility after latest changes, Makefile now
has the utility to install the binary to the system.
|
|
Iterates over the list inside um_user_data struct to free the
struct string_view buffer. This commit does not add freeing
functionality to the linked list itself.
|
|
Null-terminate all printf statements so that the output is proper.
|
|
All equalities in the codebase now uses the string_view equality
check to ensure memory-safe comparison between strings. This is
the case, unless the comparison is between two null-terminated
C-style string, in which case they will not be using sv_equal()
|
|
SV() no longer calls sv_create, instead initializes the struct
in-place.
|
|
Optimized and bug-prone equality operation for string_view struct.
This function will replace the equality checks operations between
char* + string_view, and string_view + string_view.
|
|
Added error returns to subcommands and searching utility in main()
and error codes PKGNOTFOUND and USAGE were added to err.h. The
functions will now be able to return error states to main().
|
|
The install command traverses through the linked list and checks
for the existence of package in the upstream server.
|
|
Ignore build directory.
|
|
Added both .gitignore and Makefile to build subsystem.
|
|
Makefile is added for convenience, and debug and prod builds now
exist.
|
|
Added a string view copy function to lib/sv.h. The function is
created to make it easier to copy string_views, and it is user's
responsibility to free the string_view's.
|
|
Remove userdata argument from um_init() temporarily.
|
|
Added subsystem file that describes each subsystem per file
matching.
|
|
Field userdata in parser struct is not set inside parser_init,
causing segfault on userdata access.
|
|
um.h and um.c is modified to accept the linked list ll_manifest
inside um_user_data struct. um_on_kv() now adds to the linked
list in parser->userdata.
|
|
O(n) add linked list was created with an add function. A foreach
macro is also implemented as LL_FOREACH(). This linked list is
temporary, and consists only of nodes.
|
|
On net_init failure, the application did not return any error message.
To help with error-checking, an stderr is outputted after a bad return
from net_init() on main.c
|
|
|