Sep 10, 2018 17:08
I'm considering asking a question but not sure if it's "opinion-based":
Why does apple require a legal name to be displayed as the seller on the app store (for individuals) as opposed to allowing for selecting a display name (in addition to providing your legal name to Apple)?
 

 /dev/chat

General discussion for unix.stackexchange.com. If you have a q...
Jul 11, 2018 21:33
@Kusalananda thank you for clarifying!
Jul 11, 2018 20:12
@Kusalananda
> @JBallin Ah, but in that particular context (the brew(1) manual), it is assumed that the variable is also an environment variable. So, export HOMEBREW_UPGRADE_CLEANUP=1.

Realized the docs do say to do above (RTFM...) but I'm a little confused why we'd set the var to 1 (falsey) instead of 0 (truthy)
Jul 10, 2018 22:28
How do I "set" a variable in bash? `set var`? `export var`? `var = 0`?

> If...HOMEBREW_UPGRADE_CLEANUP is set then...
Jun 17, 2018 01:19
Jun 16, 2018 22:52
another example: [ -f /usr/local/etc/bash_completion ] && . /usr/local/etc/bash_completion
Jun 16, 2018 22:49
Why is it often advised to check for the existence of a file before sourcing it? I would want to know if the file I'm trying to source doesn't exist...otherwise it's a silent "error"

```
if [ -f `brew --prefix`/etc/bash_completion ]; then
. `brew --prefix`/etc/bash_completion
fi
```
Jun 10, 2018 06:13
I figured out a workaround to my curl issue btw @FaheemMitha, I think it may have been gist.github specific. I realized I could just use gist -r ID to read the gist (using github.com/defunkt/gist) thanks for your input!
Jun 10, 2018 05:32
Thanks for clarifying @Kusalananda!
Jun 10, 2018 02:02
@FaheemMitha I can't give a specific link as it seems to be time sensitive. Go to gist.github.com, create a gist, click raw, take the link up until /raw/ and try curl link, now add a change to the gist, and curl it, and even though the link will show the change, the curl output will not
Jun 10, 2018 00:32
I'm specifically using the raw link to my GitHub gist
Jun 10, 2018 00:31
I'm having some kind of delay with curl. I update the content on a page, and confirm that it's been updated by looking at it in the browser (raw text) and then when I curl it, the updates aren't shown. If I wait like a minute, it seems to work properly. What's the reason?
Jun 9, 2018 22:08
interesting. can you explain that trade-off? @Jesse_b
Jun 9, 2018 22:02
@Jesse_b checkout the script I'm using gist.github.com/JBallin/17758cfed06e7415209ce3335490745b
Jun 9, 2018 21:46
hmm that's basically what they put in, with some minor changes (single [] etc.), the bash completion is added manually
Jun 9, 2018 21:40
why would you ever want to use \., it just makes things more confusing
Jun 9, 2018 21:38
@Jesse_b, what was ur issue? the increased shell startup time?
Jun 9, 2018 21:33
I'm asking about the last line: \. "$NVM_DIR/nvm.sh"
Jun 9, 2018 21:31
Is there a difference between source vs. `.` vs `\.`?

Saw `\.` for the first time here: https://github.com/creationix/nvm/blob/master/README.md#manual-upgrade

(
cd "$NVM_DIR"
git fetch --tags origin
git checkout `git describe --abbrev=0 --tags --match "v[0-9]*" $(git rev-list --tags --max-count=1)`
) && \. "$NVM_DIR/nvm.sh"

As an aside, why do you think he wrote the first few commands in parens instead of using `&&`?
Jun 9, 2018 20:40
Ah, thank you @MichaelHomer!
Jun 9, 2018 20:37
@Jesse_b good call. Set to "toggle_theme dark; clear", seems to work well!
Jun 9, 2018 20:26
printenv doesn't return anything noteworthy when comparing the two profiles
Jun 9, 2018 20:26
I have different keybindings for which profile I want to open
Jun 9, 2018 20:25
Jun 9, 2018 20:24
By "profile", I mean the color of the window. Basic is a white background with black text, homebrew is a black background with green text.
Jun 9, 2018 20:24
Is there a way to check which profile I'm running in terminal (Mac)? If I'm running "basic" I want to run a script to change my atom theme to be light, if I'm running "homebrew" I want to change my atom theme to be dark. Any ideas?
Apr 21, 2018 22:52
got it thanks @Jesse_b. Im about to start the learnyounode tutorial and I'm trying to figure out a way to make it work without installing the npm package globally.
https://github.com/workshopper/learnyounode
Apr 21, 2018 22:49
so it goes up a directory to find that file right? I can't find that file. It doesnt matter what dir I'm in when I call the executable and I don't see that file in /usr/local? @Jesse_b
Apr 21, 2018 22:42
What does this file do? It's an executable in /usr/local/bin
```
#!/usr/bin/env node

require('../learnyounode').execute(process.argv.slice(2))
```
Apr 4, 2018 21:54
why isn't test deleted? inner is deleted though
Apr 4, 2018 21:53
$ mkdir test && mkdir test/inner
$ cd test/inner
$ rm -rf ../../test
Apr 1, 2018 21:46
thank you @Kusalananda!
Apr 1, 2018 21:09
Why can't I delete a folder using rmdir ., I have to do rmdir ../FOLDERNAME. Just for protection against errors?
Feb 21, 2018 20:35
^ solved
Feb 21, 2018 20:35
PS1=YOUR PROMPT HERE (without newline)

reset_prompt () {
  PS1="\n$PS1"
}
PROMPT_COMMAND='(( PROMPT_CTR-- < 0 )) && {
  unset PROMPT_COMMAND PROMPT_CTR
  reset_prompt
}'
Feb 21, 2018 20:22
so I found a decent solution. now I'm wondering the best way to add a new line to an existing PS1. Something like PS1='\n$PS1' (which isn't working)
Feb 21, 2018 20:09
```

$
```
vs.
```
$
```
Feb 21, 2018 20:08
I have my bash prompt printing a new line before the prompt to give me space between the last command. the issue is that the new line is also there on login. any ideas for how I could eliminate that new line?
Feb 12, 2018 17:56
works now
Feb 12, 2018 17:56
ah, thanks!
Feb 12, 2018 17:51
hey I'm trying to enable syntax highlighting in nano so I added the following to ~/.nanorc:
include "FILEPATH/javascript.nanorc"
but when I source the file I get:
bash: include: command not found
Feb 9, 2018 18:56
shows me which branch i'm on
Feb 9, 2018 18:56
yea i have a basic git status
Feb 9, 2018 18:55
i thought i might as well make it look "sexy"
Feb 9, 2018 18:55
im actually just using the command line for git mainly
Feb 9, 2018 18:48
i have a pretty basic bash_profile that's "good enough" but this is kind of interesting: gist.github.com/kevin-smets/8568070
Feb 9, 2018 18:47
well if i havent used either extensively, which would you recommend getting into
Feb 9, 2018 18:42
how'd you choose bash over zsh?
Feb 9, 2018 18:42
sounds good thanks guys!
Feb 9, 2018 18:37
i was thinking of trying out oh-my-zsh. it's trustworthy right?