[Webinar] Streamline your web hosting managementRegister Today

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 403
  • Last Modified:

remove uncompiled c code from folder

Hi I want to only leave the c program binaries (compiled code) in a folder.

how do i remove uncompiled code using the command line?
0
gerrymac1943
Asked:
gerrymac1943
3 Solutions
 
Neil RussellTechnical Development LeadCommented:
rm *.c
rm*.h

Is a good starting point. But would be better to just compile your target to a different folder.
0
 
farzanjCommented:
You could use the find command

find / -type f -name *.c -name *.h

Make the path as conservative as possible.  Once you are able to list, you can pipe the list to
| xargs rm
0
 
arnoldCommented:
You should move the compiled program/s out rather than the source and the compiled objects. Work on the issue with the fewer items.
Usually you want to keep the source in the event you want to make changes in the future.
0
 
gerrymac1943Author Commented:
excellent
0

Featured Post

Never miss a deadline with monday.com

The revolutionary project management tool is here!   Plan visually with a single glance and make sure your projects get done.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now