浏览代码

Strip cwd path for all non-Linux platforms

master
Arun Prakash Jana 5 年前
父节点
当前提交
0647c75cd8
找不到此签名对应的密钥 GPG 密钥 ID: A75979F35C080412
共有 1 个文件被更改,包括 1 次插入3 次删除
  1. +1
    -3
      src/nnn.c

+ 1
- 3
src/nnn.c 查看文件

@@ -1301,11 +1301,9 @@ static void archive_selection(const char *cmd, const char *archive, const char *
snprintf(buf, CMD_LEN_MAX,
#ifdef __linux__
"sed -ze 's|^%s/||' '%s' | xargs -0 %s %s", curpath, g_cppath, cmd, archive);
#elif defined __APPLE__
#else
"cat '%s' | tr '\\0' '\n' | sed -e 's|^%s/||' | tr '\n' '\\0' | xargs -0 %s %s",
g_cppath, curpath, cmd, archive);
#else
"cat %s | xargs -0 -o %s %s", g_cppath, cmd, archive);
#endif
spawn("sh", "-c", buf, curpath, F_NORMAL);
free(buf);


正在加载...
取消
保存