aboutsummaryrefslogtreecommitdiff
path: root/src/install_pkg.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/install_pkg.c')
-rw-r--r--src/install_pkg.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/install_pkg.c b/src/install_pkg.c
index c0809e8..e92eab2 100644
--- a/src/install_pkg.c
+++ b/src/install_pkg.c
@@ -6,6 +6,7 @@
#include "add_repo.h"
#include "build.h"
#include "fetch_src.h"
+#include "files.h"
#include "install_pkg.h"
#include "lua_state.h"
#include "name_from_url.h"
@@ -27,7 +28,11 @@ void install_pkg(Pkg pkg) {
}
}
- if (!pkg.is_local) {
+ if (pkg.is_local) {
+ char cwd[MAX_PATH_LEN];
+ getcwd(cwd, MAX_PATH_LEN);
+ cpdir(cwd, pkg.src);
+ } else {
printf(
"%s fetching %s%s%s\n",
print_pkgit, green, pkg.name, color_reset