Questions tagged [braces]
5 questions
6
votes
1 answer
Prevent braces in BASH to create sub-shell
I need braces to specify evaluation priority of expressions, but I don't want braces to create sub-scripts. Look what happens when that example code is ran:
Example script
#!/bin/bash
false || (echo "First" && exit 1)
false || (echo "Second" &&…
java.is.for.desktop
- 1,858
4
votes
2 answers
Formatting of braces for C++ in Visual Studio Code
I've C/C++ extension of Microsoft as my default formatter. When I save/run my code the opening curly braces automatically move to newline instead of staying in sameline. How can I prevent this? (It doesn't happen after I disable the extension.)
In…
Shub
- 240
- 3
- 11
2
votes
1 answer
Notepad++ Search/Replace Comments { inside } Curly Brackets
is there a way in Notepad++ (whether by Regex or some other way) to replace/remove comments within curly brackets?
{ some comments { nested comments } need to be deleted }
I want to remove the comments inside, or completely remove the comments…
Swoop
- 43
2
votes
1 answer
Another Bracket Script issue
I use AutoHotKey to autocomplete all kind of brackets in the following way:
typing ( gives ( -> opening brace bracket only
typing (( gives () -> open & close brace with input cursor between the braces.
The same thing happen for square…
Michel
- 21
1
vote
1 answer
rsync curly braces with one item issue?
I have a problem with rsync when I pass the exclude list in curly braces, what is the difference between the following two lines?
sudo rsync -aHAXxhvi --delete --exclude={/1111111/} /etc/ /media/destino/etc/
sudo rsync -aHAXxhvi --delete…
Sagitariozod
- 11