Skip to content

Commit

Permalink
fix: file listing in sftp(#754) (#1133)
Browse files Browse the repository at this point in the history
  • Loading branch information
bajrangCoder authored Jan 4, 2025
1 parent ef83962 commit e53ea06
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/fileSystem/sftp.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ class SftpClient {
if (stat) options += "d";

sftp.exec(
`ls ${options} --full-time -L "${path}" | awk '{$2=\"\"; print $0}'`,
`/usr/bin/ls ${options} --full-time -L "${path}" | awk '{$2=\"\"; print $0}'`,
async (res) => {
if (res.code <= 0) {
if (stat) {
Expand Down Expand Up @@ -574,7 +574,7 @@ class SftpClient {

targetType = await new Promise((resolve, reject) => {
sftp.exec(
`ls -ld "${this.#safeName(linkTarget)}"`,
`/usr/bin/ls -ld "${this.#safeName(linkTarget)}"`,
(res) => {
if (res.code <= 0) {
const output = res.result.trim();
Expand Down

0 comments on commit e53ea06

Please sign in to comment.