Jeff Woods wrote: > > for file in prefix-* ; do > > mv "$file" "${file##prefix-}" > > done > > Almost correct. > What happens if one of the files is named "prefix-prefix-1"? It gets renamed to prefix-1, which is what I would expect. > What about "prefix-"? > > I suggest: > > for file in prefix-?* > do > mv "$file" "${file#prefix-}" > done Huh? -- Glynn Clements <glynn@xxxxxxxxxxxxxxxxxx> - : send the line "unsubscribe linux-admin" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html