Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

The command I am using is:

wget -r -nH ftp://some.domain.com/home/work/test/* -P ./my

The output directory becomes:

./my/home/work/test/*

How can I make it to just ./my/*?

share|improve this question

migrated from stackoverflow.com Nov 29 '12 at 14:52

This question came from our site for professional and enthusiast programmers.

    
StackOverflow is for programming questions. –  kazanaki Nov 29 '12 at 14:51
add comment

2 Answers

up vote 2 down vote accepted

Use --cut-dirs option. In Your case, --cut-dirs=3 to cut off home, work and test.

share|improve this answer
add comment

See the fine manual for a description of the --cut-dirs option.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.