Commit Graph

71 Commits

Author SHA1 Message Date
Nathan Fisher
13a97ff1d8 Adjust package installer to take &mut hooks as a parameter, which will
be passed to each package is it is installed with all hooks being run
after all packages have finished installation. Also fix some ordering
issues with package installation so that post install scripts and
appstream data are not included in the number of archive members for the
sake of progress bars, etc.
2023-04-16 19:15:12 -04:00
Nathan Fisher
f479dd28ad Add install_local function to cli app 2023-04-15 01:21:12 -04:00
Nathan Fisher
7fe884cd3e Add method to create an Installer struct from an archive path 2023-04-14 01:03:52 -04:00
c36b3b14ab Use try_for_each_with in Installer::install to avoid using a mutex
on the Sender.
2023-04-12 11:25:12 -04:00
d3b5d096e5 Use try_for_each_with in Creator::create in order to avoid putting
Sender in a mutex and return errors rather than passing messages
2023-04-12 11:15:13 -04:00
be0c8dc6e7 Massage Installer for better code readability 2023-04-11 22:37:02 -04:00
Nathan Fisher
13dff6bd96 Get basic package installation implemented, with several TODOS left. 2023-04-11 14:05:37 -04:00
f4e87ee500 Merge remote-tracking branch 'hpk-cli/odin' into odin;
This commit brings the cli `hpk` binary back into the `hpk` crate and
places it behind a feature flag, enabling development to take place in a
single repository.
2023-04-10 01:06:01 -04:00
1a4d202989 Expand InstallerError enum; 2023-04-08 11:45:39 -04:00
784069402d Merge branch 'odin' of git.hitchhiker-linux.org:jeang3nie/hpk into odin 2023-04-08 10:16:10 -04:00
Nathan Fisher
ab6e7441f1 Create Installer struct 2023-04-07 19:12:28 -04:00
Nathan Fisher
a07166375a Add Arch to Update struct 2023-04-06 18:47:53 -04:00
ca9c0d7cdb Skip directories when creating a package from directory; Take an
optional directory when creating a package from file list;
2023-04-06 10:41:10 -04:00
c5450c34ef Update package-bootstrap crate 2023-04-05 22:37:25 -04:00
Nathan Fisher
8a06b3c628 Merge branch 'odin' of git.hitchhiker-linux.org:jeang3nie/hpk into odin 2023-04-04 22:52:42 -04:00
Nathan Fisher
8907831877 Update hpk-package 2023-04-04 22:52:19 -04:00
c099790f5a Remove .cargo from git 2023-04-04 20:18:29 -04:00
Nathan Fisher
1e101f7e70 Update hpk crate, which now has hpk-package split out 2023-04-03 19:04:37 -04:00
Nathan Fisher
082c215b44 Split out hpk-package into separate crate; Implement Repository::build() 2023-04-03 19:02:15 -04:00
9126e1da93 Version - use tuple types instead of structs for less verbosity 2023-04-01 11:02:29 -04:00
a1843cac33 Check for package upgrades in parallel; Search in packages in parallel; 2023-04-01 02:01:53 -04:00
Nathan Fisher
26be99f408 Completed 2/3 of methods added in previous commit; Added some tests; 2023-03-31 19:08:53 -04:00
4d0dfc1df4 stubbed some methods for db interaction 2023-03-31 12:23:48 -04:00
bbb611c77c Added constants and functions for getting the effective database path
and cache directory
2023-03-31 11:39:20 -04:00
ccd163edf5 Remove nativ_tls option for ureq, as it greatly complicates cross
compiling
2023-03-31 01:03:54 -04:00
Nathan Fisher
eae02ce616 Clean up imports after last commit 2023-03-30 19:07:12 -04:00
Nathan Fisher
71a87a506e Adjust Creator struct to use Vec<PathBuf> instead of Vec<DirEntry>;
Add `from_list` method for `Creator`
2023-03-30 18:43:11 -04:00
Nathan Fisher
efb28a30e2 Fix for dependency resolution - take into account release number 2023-03-30 10:59:02 -04:00
Nathan Fisher
8b52ded12c Tweaked command line options; Fixed manpage installation paths; 2023-03-30 00:46:14 -04:00
94eb94952f Merge branch 'odin' of git.hitchhiker-linux.org:jeang3nie/hpk into odin 2023-03-29 23:33:28 -04:00
9f4d26b338 Added some db/repo methods; Add deny.toml; Replace reqwests with
`ureq` crate;
2023-03-29 23:31:59 -04:00
Nathan Fisher
e8aead5365 Implement PartialEq and PartialOrd between SemVer and Rapid versioning 2023-03-29 00:18:49 -04:00
Nathan Fisher
1acf6f4051 Add Rapid versioning (ala Gnome, Firefox, Chrome) with single decimal 2023-03-28 23:58:18 -04:00
4b7f5afa56 Added value hints for cli 2023-03-28 21:27:40 -04:00
efe77b97d8 Added progress bar styling 2023-03-28 21:18:55 -04:00
0a94691685 Small tweak in message passing 2023-03-28 20:41:03 -04:00
cf9d6aa7e6 Add progress bars for package creation 2023-03-28 19:28:37 -04:00
3d0151610d Fix long filenames when creating tar header from metadata and filename
rather than path
2023-03-28 19:16:38 -04:00
4c80e08731 fix storing filenames longer than 100bytes in tar headers 2023-03-28 19:14:17 -04:00
749bac6876 Remove stdout message on writing package.ron 2023-03-28 17:53:44 -04:00
3a5174c521 Added len method to Creator 2023-03-28 17:34:14 -04:00
e8aa73bf9d Split off from hpk crate 2023-03-28 17:12:41 -04:00
1160730e1f Moved cli binary and bootstrapper into separate crate 2023-03-28 16:57:13 -04:00
026e8599a5 Move cli into module rather than workspace member 2023-03-28 00:16:12 -04:00
e1f7fbe4fe Fix bugs in Creator so that it works now 2023-03-28 00:09:16 -04:00
3b88759665 Cleaned up imports from previous commit 2023-03-27 03:26:51 -04:00
39b8664c9e Added package Creator struct, with create method to process package
entries fully multithreaded including compressing into the archive, as
well as passing messages through an mpsc::channel() interface for use in
a background thread in various frontends. Much better suited to task
than previous `create_package` function. Untested.
2023-03-27 03:18:20 -04:00
33955fa836 Made completions generation more generic 2023-03-26 02:13:13 -04:00
e345ca6abb Add bootstrap binary 2023-03-26 01:43:32 -04:00
00e48a9f9a Fix ownership issues with previous commit 2023-03-25 18:03:51 -04:00