Sample Header Ad - 728x90

How to remove only links, but not actual files?

0 votes
1 answer
200 views
I have a folder full of .svg files, some of which are actual files and others are merely links to files. They both have the .svg file extension, however the actual files are labeled "SVG Image" and the links are labeled "Link to SVG Image". I only want to delete the links, but I can't rm *.svg because they both have the file extension .svg. I can do ls and it shows the actual files vs symlinks in different colors so there is definitely a distinction. There are also far too many files to sort manually, which is why I want to be able to do this via a terminal command.
Asked by Jeff Chen (133 rep)
Dec 14, 2021, 03:16 AM
Last activity: Dec 14, 2021, 01:58 PM