question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

mv: illegal option -- T

See original GitHub issue

An error is produced on FreeBSD. It seems that FreeBSD does not have -T option for mv command. This option was introduced with shipit-deploy 2.5.0

'deploy:publish' errored after 553 ms
Error: Command failed: ssh user@server "cd /usr/home/…/nodejs && if [[ -d current && ! (-L current) ]]; then echo \"ERR: could not make symlink\"; else ln -nfs releases/20171204175536 current_tmp && mv -fT current_tmp current; fi"
mv: illegal option -- T
usage: mv [-f | -i | -n] [-hv] source target
       mv [-f | -i | -n] [-v] source ... directory

Issue Analytics

  • State:open
  • Created 6 years ago
  • Reactions:1
  • Comments:7 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
gregbergecommented, Mar 17, 2018

I close it, feel free to reopen it after v4.

0reactions
Firercommented, Dec 29, 2020

I also ran into the same issue deploying to FreeBSD. I have a workaround monkey patch in my shipitfile.js which seems to be working. The equivalent to -T on FreeBSD for this specific use case is -h.

  shipit.blTask('fix-freebsd-mv', () => {
    shipit.pool.connections.forEach(connection => {
      const { run } = connection;

      connection.run = (cmd, options) => {
        cmd = cmd.replaceAll('mv -fT', 'mv -fh');
        return run.call(connection, cmd, options);
      }
    });
  });

  shipit.on('deploy', () => {
    return shipit.start(['fix-freebsd-mv']);
  });
Read more comments on GitHub >

github_iconTop Results From Across the Web

macOS/bash equivalent of mv -t - Unix & Linux Stack Exchange
It is the mv command. You can install gnu mv , to get the -t option. Alternatively see other answers, but with this...
Read more >
makefile - mv command not working on mac - Stack Overflow
The -t flag is not defined in the man pages of my mac so I'm wondering how I can get around this. makefile...
Read more >
bash - error when trying to mv a file with -r in the name of the file
I can't picture a case where having find look for an inode number is better than just using find's own filename matching like...
Read more >
Why does 'mv' not need '-r' to work with directories, but 'rm' and ...
We surely aren't likely to want to rename a directory and all its ... to implement mv for a directory it does not...
Read more >
Linux mv command help and examples - Computer Hope
Never make backups, even if the --backup option is given. numbered, t, Make numbered backups. existing, nil, numbered if numbered backups ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found