From 518be7f92e2c2bc1a3cc3cfe1223390ae3cd9c2b Mon Sep 17 00:00:00 2001 From: dacctal Date: Fri, 17 Jul 2026 23:12:40 +0000 Subject: update! --- include/check.h | 24 ++++++++++++++++++++++++ include/files.h | 4 ++++ include/is_updated.h | 28 ++++++++++++++++++++++++++++ include/pkgit_lua.h | 7 +++++++ 4 files changed, 63 insertions(+) create mode 100644 include/check.h create mode 100644 include/is_updated.h (limited to 'include') diff --git a/include/check.h b/include/check.h new file mode 100644 index 0000000..c43385b --- /dev/null +++ b/include/check.h @@ -0,0 +1,24 @@ +/* + + pkgit - package it! + + Copyright (C) 2026 dacctal + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +*/ + +#ifndef PKGIT_CHECK_H +#define PKGIT_CHECK_H +void check(void); +#endif diff --git a/include/files.h b/include/files.h index 24712e9..8054bd8 100644 --- a/include/files.h +++ b/include/files.h @@ -23,7 +23,11 @@ #include +#include "str.h" + bool file_exists(const char *path); bool is_directory(const char *path); +str cmd_out(const char *cmd); +void cpdir(const char *src_path, const char *dst_path); #endif diff --git a/include/is_updated.h b/include/is_updated.h new file mode 100644 index 0000000..16f998f --- /dev/null +++ b/include/is_updated.h @@ -0,0 +1,28 @@ +/* + + pkgit - package it! + + Copyright (C) 2026 dacctal + This program is free software: you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation, either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see . + +*/ + +#ifndef PKGIT_IS_UPDATED_H +#define PKGIT_IS_UPDATED_H + +#include +#include "str.h" +bool is_updated(str *src); + +#endif diff --git a/include/pkgit_lua.h b/include/pkgit_lua.h index f5f86a1..eee5160 100644 --- a/include/pkgit_lua.h +++ b/include/pkgit_lua.h @@ -53,6 +53,9 @@ bool lua_try_function(lua_State *L, char *lua_file, char *fname); bool lua_try_table(lua_State *L, char *lua_file, char *tname); bool pkg_exists(str *name); str pkg_get_url(str *name); +str bldit_getver(void); +str bldit_pkg_getver(void); +bool is_bldit_usable(void); // install void install_dependencies(lua_State *L); @@ -64,4 +67,8 @@ bool bldit_uninstall(package_t *pkg); bool config_uninstall(package_t *pkg); void pkg_remove(package_t *pkg); +// update +void pkg_update(package_t *pkg); +void all_update(void); + #endif -- cgit v1.2.3