Timeline for How can I replace a character in all the .php files inside a folder on OS X?
Current License: CC BY-SA 3.0
        18 events
    
    | when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jan 23, 2016 at 10:26 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    added 2 characters in body 
                
             | 
| Jan 23, 2016 at 10:26 | comment | added | Pandya | @Andrei tell me if find . -name "*.php" -exec sed -i '' -f replace.sed '{}' \;works (revised answer)? | |
| Jan 23, 2016 at 10:18 | comment | added | Andrei | @Pandya that command does not work. It gives the error Find: illegal option -n. I made it work however with the following command:find test -iname "*.php" -exec sed -i '' -f test/replace.sed '{}' \;wheretestis the folder containing the files. | |
| Jan 20, 2016 at 1:27 | comment | added | Pandya | @Andrei Have you tried findcommand given in answer? | |
| Jan 19, 2016 at 16:09 | comment | added | Andrei | And how can I use this command to go inside all subfolders? for i in *.php; do sed -i '' -f replace.sed "$i"; done | |
| Jan 19, 2016 at 12:22 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    added 397 characters in body 
                
             | 
| Jan 19, 2016 at 12:21 | comment | added | Stéphane Chazelas | sedhas aycommand for transliteration. | |
| Jan 19, 2016 at 12:20 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    added 397 characters in body 
                
             | 
| Jan 19, 2016 at 12:13 | history | edited | Stéphane Chazelas | CC BY-SA 3.0 | 
                
                    On OS/X the argument to -i is required. 
                
             | 
| Jan 19, 2016 at 12:08 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    deleted 24 characters in body 
                
             | 
| Jan 18, 2016 at 21:57 | comment | added | Wildcard | @Pandya, OS X uses BSD sed.  You have to provide an extension to the-ioption or it won't work.  I recommend-i .bak. | |
| Jan 18, 2016 at 16:17 | comment | added | Pandya | @Andrei see revised post. Note that -ioption withsedwill replace the old files | |
| Jan 18, 2016 at 16:17 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    added 179 characters in body 
                
             | 
| Jan 18, 2016 at 16:02 | comment | added | Andrei | And how can I make it go through all the files inside a specific folder? | |
| Jan 18, 2016 at 15:50 | comment | added | Pandya | @Kira see revised post | |
| Jan 18, 2016 at 15:46 | history | edited | Pandya | CC BY-SA 3.0 | 
                
                    added 542 characters in body 
                
             | 
| Jan 18, 2016 at 15:44 | comment | added | Kira | Isn't this last s(-e 's/ș/s') expression incomplete? | |
| Jan 18, 2016 at 15:43 | history | answered | Pandya | CC BY-SA 3.0 |