How to delete multiple files and directories of various locations in fedora 27

Multi tool use
Multi tool use

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












I am using fedora 27. I installed wine to emulate some Windows applications. Unfortunately, it did not work as I expected and now I want to delete all the traces of wine from Fedora. I run the basic commands as yum remove wine. But the problem is that there still a lot of wine files and directories in Fedora. After run locate wine it gave me a long list of files from various locations. I attached a print-screen with the given results. Is there a way to delete all these files excepting the manual wiping file by file?enter image description here







share|improve this question


















  • 3




    Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
    – Wouter Verhelst
    Feb 7 at 17:39










  • If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
    – dhag
    Feb 7 at 17:42














up vote
1
down vote

favorite












I am using fedora 27. I installed wine to emulate some Windows applications. Unfortunately, it did not work as I expected and now I want to delete all the traces of wine from Fedora. I run the basic commands as yum remove wine. But the problem is that there still a lot of wine files and directories in Fedora. After run locate wine it gave me a long list of files from various locations. I attached a print-screen with the given results. Is there a way to delete all these files excepting the manual wiping file by file?enter image description here







share|improve this question


















  • 3




    Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
    – Wouter Verhelst
    Feb 7 at 17:39










  • If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
    – dhag
    Feb 7 at 17:42












up vote
1
down vote

favorite









up vote
1
down vote

favorite











I am using fedora 27. I installed wine to emulate some Windows applications. Unfortunately, it did not work as I expected and now I want to delete all the traces of wine from Fedora. I run the basic commands as yum remove wine. But the problem is that there still a lot of wine files and directories in Fedora. After run locate wine it gave me a long list of files from various locations. I attached a print-screen with the given results. Is there a way to delete all these files excepting the manual wiping file by file?enter image description here







share|improve this question














I am using fedora 27. I installed wine to emulate some Windows applications. Unfortunately, it did not work as I expected and now I want to delete all the traces of wine from Fedora. I run the basic commands as yum remove wine. But the problem is that there still a lot of wine files and directories in Fedora. After run locate wine it gave me a long list of files from various locations. I attached a print-screen with the given results. Is there a way to delete all these files excepting the manual wiping file by file?enter image description here









share|improve this question













share|improve this question




share|improve this question








edited Aug 20 at 22:29









Rui F Ribeiro

35k1269113




35k1269113










asked Feb 7 at 17:27









Vales Rodriguez

61




61







  • 3




    Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
    – Wouter Verhelst
    Feb 7 at 17:39










  • If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
    – dhag
    Feb 7 at 17:42












  • 3




    Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
    – Wouter Verhelst
    Feb 7 at 17:39










  • If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
    – dhag
    Feb 7 at 17:42







3




3




Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
– Wouter Verhelst
Feb 7 at 17:39




Please don't post screenshots of text-only information; this does not add value, and indeed may make it harder for people to help you. Instead, copy-paste the information as text.
– Wouter Verhelst
Feb 7 at 17:39












If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
– dhag
Feb 7 at 17:42




If you can run a command to list files, as you did above, then there are ways to delete this list of files. But I also don't think that locate wine is the proper way to find files installed with or because of Wine.
– dhag
Feb 7 at 17:42










3 Answers
3






active

oldest

votes

















up vote
1
down vote













The command locate wine is potentially dangerous if you use its output as arguments for a remove operation like with rm. The command locate lists all files having the substring "wine" in their path, which may or may not what you are actually looking for: It could remove the list of "old-wines.txt" you are keeping for your next party, but wouldn't delete "wn-config.ini" if that is part of the package you want to get rid of.



To see the list of installed files belonging to the RPM package "wine" use rpm -ql wine. The RPM subsystem distinguishes between package files and configuration, though. To list the latter, use rpm -q --configfiles. To delete both config files and package files, use the "erase" subcommand: rpm -e.






share|improve this answer



























    up vote
    0
    down vote













    From your screenshot, a simple rm /root/.local/share/mime/packages/x-wine-extension* as root should work, but I'm assuming there are more files than shown. I would think that (with Wine installed) sudo dnf remove wine would work. Your ~/.wine folder won't be deleted, so you'll need to delete that manually.






    share|improve this answer



























      up vote
      0
      down vote













      It's not clear how many files you are looking to delete nor if they all exist in the same directory or are scattered across various paths. But I will point out that if the number of files is too large, commands like ls & rm might fail to iterate over the entire list. In this case, you can use find to build a list of the files you are interested in and then using the -exec switch it can take action on each one individually. As a safety precaution, I recommend always using find to list the files before re-running the command with the -exec switch to make sure you know which files you are about to take action on.



      For example, if you are aiming to remove only the x-wine-extension-*.xml files in /root/.local/share/mime/packages ... you would use find like this to list them:



      find /root/.local/share/mime/packages -name x-wine-extension-*.xml 


      And then to delete them you would use this:



      find /root/.local/share/mime/packages -name x-wine-extension-*.xml -exec rm ;





      share|improve this answer




















        Your Answer







        StackExchange.ready(function()
        var channelOptions =
        tags: "".split(" "),
        id: "106"
        ;
        initTagRenderer("".split(" "), "".split(" "), channelOptions);

        StackExchange.using("externalEditor", function()
        // Have to fire editor after snippets, if snippets enabled
        if (StackExchange.settings.snippets.snippetsEnabled)
        StackExchange.using("snippets", function()
        createEditor();
        );

        else
        createEditor();

        );

        function createEditor()
        StackExchange.prepareEditor(
        heartbeatType: 'answer',
        convertImagesToLinks: false,
        noModals: false,
        showLowRepImageUploadWarning: true,
        reputationToPostImages: null,
        bindNavPrevention: true,
        postfix: "",
        onDemand: true,
        discardSelector: ".discard-answer"
        ,immediatelyShowMarkdownHelp:true
        );



        );








         

        draft saved


        draft discarded


















        StackExchange.ready(
        function ()
        StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f422597%2fhow-to-delete-multiple-files-and-directories-of-various-locations-in-fedora-27%23new-answer', 'question_page');

        );

        Post as a guest






























        3 Answers
        3






        active

        oldest

        votes








        3 Answers
        3






        active

        oldest

        votes









        active

        oldest

        votes






        active

        oldest

        votes








        up vote
        1
        down vote













        The command locate wine is potentially dangerous if you use its output as arguments for a remove operation like with rm. The command locate lists all files having the substring "wine" in their path, which may or may not what you are actually looking for: It could remove the list of "old-wines.txt" you are keeping for your next party, but wouldn't delete "wn-config.ini" if that is part of the package you want to get rid of.



        To see the list of installed files belonging to the RPM package "wine" use rpm -ql wine. The RPM subsystem distinguishes between package files and configuration, though. To list the latter, use rpm -q --configfiles. To delete both config files and package files, use the "erase" subcommand: rpm -e.






        share|improve this answer
























          up vote
          1
          down vote













          The command locate wine is potentially dangerous if you use its output as arguments for a remove operation like with rm. The command locate lists all files having the substring "wine" in their path, which may or may not what you are actually looking for: It could remove the list of "old-wines.txt" you are keeping for your next party, but wouldn't delete "wn-config.ini" if that is part of the package you want to get rid of.



          To see the list of installed files belonging to the RPM package "wine" use rpm -ql wine. The RPM subsystem distinguishes between package files and configuration, though. To list the latter, use rpm -q --configfiles. To delete both config files and package files, use the "erase" subcommand: rpm -e.






          share|improve this answer






















            up vote
            1
            down vote










            up vote
            1
            down vote









            The command locate wine is potentially dangerous if you use its output as arguments for a remove operation like with rm. The command locate lists all files having the substring "wine" in their path, which may or may not what you are actually looking for: It could remove the list of "old-wines.txt" you are keeping for your next party, but wouldn't delete "wn-config.ini" if that is part of the package you want to get rid of.



            To see the list of installed files belonging to the RPM package "wine" use rpm -ql wine. The RPM subsystem distinguishes between package files and configuration, though. To list the latter, use rpm -q --configfiles. To delete both config files and package files, use the "erase" subcommand: rpm -e.






            share|improve this answer












            The command locate wine is potentially dangerous if you use its output as arguments for a remove operation like with rm. The command locate lists all files having the substring "wine" in their path, which may or may not what you are actually looking for: It could remove the list of "old-wines.txt" you are keeping for your next party, but wouldn't delete "wn-config.ini" if that is part of the package you want to get rid of.



            To see the list of installed files belonging to the RPM package "wine" use rpm -ql wine. The RPM subsystem distinguishes between package files and configuration, though. To list the latter, use rpm -q --configfiles. To delete both config files and package files, use the "erase" subcommand: rpm -e.







            share|improve this answer












            share|improve this answer



            share|improve this answer










            answered Feb 7 at 19:03









            Nils Magnus

            1653




            1653






















                up vote
                0
                down vote













                From your screenshot, a simple rm /root/.local/share/mime/packages/x-wine-extension* as root should work, but I'm assuming there are more files than shown. I would think that (with Wine installed) sudo dnf remove wine would work. Your ~/.wine folder won't be deleted, so you'll need to delete that manually.






                share|improve this answer
























                  up vote
                  0
                  down vote













                  From your screenshot, a simple rm /root/.local/share/mime/packages/x-wine-extension* as root should work, but I'm assuming there are more files than shown. I would think that (with Wine installed) sudo dnf remove wine would work. Your ~/.wine folder won't be deleted, so you'll need to delete that manually.






                  share|improve this answer






















                    up vote
                    0
                    down vote










                    up vote
                    0
                    down vote









                    From your screenshot, a simple rm /root/.local/share/mime/packages/x-wine-extension* as root should work, but I'm assuming there are more files than shown. I would think that (with Wine installed) sudo dnf remove wine would work. Your ~/.wine folder won't be deleted, so you'll need to delete that manually.






                    share|improve this answer












                    From your screenshot, a simple rm /root/.local/share/mime/packages/x-wine-extension* as root should work, but I'm assuming there are more files than shown. I would think that (with Wine installed) sudo dnf remove wine would work. Your ~/.wine folder won't be deleted, so you'll need to delete that manually.







                    share|improve this answer












                    share|improve this answer



                    share|improve this answer










                    answered Feb 7 at 17:43









                    zaen

                    154




                    154




















                        up vote
                        0
                        down vote













                        It's not clear how many files you are looking to delete nor if they all exist in the same directory or are scattered across various paths. But I will point out that if the number of files is too large, commands like ls & rm might fail to iterate over the entire list. In this case, you can use find to build a list of the files you are interested in and then using the -exec switch it can take action on each one individually. As a safety precaution, I recommend always using find to list the files before re-running the command with the -exec switch to make sure you know which files you are about to take action on.



                        For example, if you are aiming to remove only the x-wine-extension-*.xml files in /root/.local/share/mime/packages ... you would use find like this to list them:



                        find /root/.local/share/mime/packages -name x-wine-extension-*.xml 


                        And then to delete them you would use this:



                        find /root/.local/share/mime/packages -name x-wine-extension-*.xml -exec rm ;





                        share|improve this answer
























                          up vote
                          0
                          down vote













                          It's not clear how many files you are looking to delete nor if they all exist in the same directory or are scattered across various paths. But I will point out that if the number of files is too large, commands like ls & rm might fail to iterate over the entire list. In this case, you can use find to build a list of the files you are interested in and then using the -exec switch it can take action on each one individually. As a safety precaution, I recommend always using find to list the files before re-running the command with the -exec switch to make sure you know which files you are about to take action on.



                          For example, if you are aiming to remove only the x-wine-extension-*.xml files in /root/.local/share/mime/packages ... you would use find like this to list them:



                          find /root/.local/share/mime/packages -name x-wine-extension-*.xml 


                          And then to delete them you would use this:



                          find /root/.local/share/mime/packages -name x-wine-extension-*.xml -exec rm ;





                          share|improve this answer






















                            up vote
                            0
                            down vote










                            up vote
                            0
                            down vote









                            It's not clear how many files you are looking to delete nor if they all exist in the same directory or are scattered across various paths. But I will point out that if the number of files is too large, commands like ls & rm might fail to iterate over the entire list. In this case, you can use find to build a list of the files you are interested in and then using the -exec switch it can take action on each one individually. As a safety precaution, I recommend always using find to list the files before re-running the command with the -exec switch to make sure you know which files you are about to take action on.



                            For example, if you are aiming to remove only the x-wine-extension-*.xml files in /root/.local/share/mime/packages ... you would use find like this to list them:



                            find /root/.local/share/mime/packages -name x-wine-extension-*.xml 


                            And then to delete them you would use this:



                            find /root/.local/share/mime/packages -name x-wine-extension-*.xml -exec rm ;





                            share|improve this answer












                            It's not clear how many files you are looking to delete nor if they all exist in the same directory or are scattered across various paths. But I will point out that if the number of files is too large, commands like ls & rm might fail to iterate over the entire list. In this case, you can use find to build a list of the files you are interested in and then using the -exec switch it can take action on each one individually. As a safety precaution, I recommend always using find to list the files before re-running the command with the -exec switch to make sure you know which files you are about to take action on.



                            For example, if you are aiming to remove only the x-wine-extension-*.xml files in /root/.local/share/mime/packages ... you would use find like this to list them:



                            find /root/.local/share/mime/packages -name x-wine-extension-*.xml 


                            And then to delete them you would use this:



                            find /root/.local/share/mime/packages -name x-wine-extension-*.xml -exec rm ;






                            share|improve this answer












                            share|improve this answer



                            share|improve this answer










                            answered Feb 7 at 18:50









                            SEdude

                            12




                            12






















                                 

                                draft saved


                                draft discarded


























                                 


                                draft saved


                                draft discarded














                                StackExchange.ready(
                                function ()
                                StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f422597%2fhow-to-delete-multiple-files-and-directories-of-various-locations-in-fedora-27%23new-answer', 'question_page');

                                );

                                Post as a guest













































































                                UbJfc2Wbl vRiYco 7LSHXEsrGktP,gc 9
                                4DVWrHw2xB8,B,hInk

                                Popular posts from this blog

                                How to check contact read email or not when send email to Individual?

                                How many registers does an x86_64 CPU actually have?

                                Displaying single band from multi-band raster using QGIS