[10:22:01] T367135 (re @jhsoby: What's UP with this in the Gerrit UI? (To reproduce: Hit "Reply" on a task and try to add a reviewer.)) [12:31:57] الو [12:33:40] لو سمحتو أنا سعودي مواطن لايوجد لدي وظيفه عندي شهاده ولا سياره وساهر مخالفات منع كل الحياه منا تساعدونى ولا وعد مني لكم اني لا اخذ بحقي من الاول وبالتالي وكلمتي بثمن [16:05:20] wm-bb should be bridging this channel again now that the network is happier [18:50:24] Can anyone explain what's going on here, : ``` [18:50:25] $ ssh login.toolforge.org become commons-upload-map pwd [18:50:26] /mnt/nfs/labstore-secondary-tools-project/commons-upload-map [18:50:28] $ ssh login.toolforge.org become commons-upload-map bash -c "cd commons-upload-map && pwd" [18:50:29] /mnt/nfs/labstore-secondary-tools-home/tuukka``` [18:51:08] Also, did my tests with these commands kill Toolforge (again)? 😱 [18:58:22] @tuukkahastrup probably this ^ (re @wmtelegram_bot: @waldyrious: I would guess the issue with a "bash -c ...." is shell tokenization ending up confused. Ultimately `become`...) [18:59:46] I think it's not a problem with the shell but the quoting problems of ssh. Anyway, this works: ``` [18:59:46] $ ssh login.toolforge.org become commons-upload-map 'bash -c "cd commons-upload-map && pwd"'``` [19:07:12] (Something like whenever you have quotes, SSH will eat one set of them.) [19:08:58] And here the final recipe to update code from git in one command: `ssh login.toolforge.org 'become commons-upload-map bash -c "cd commons-upload-map && git pull"'` [19:15:25] if you’re really only using git pull, I think you could simplify that to [19:15:25] `ssh login.toolforge.org become commons-upload-map git -C commons-upload-map pull` [19:15:52] (`git -C` switches to the specified directory before doing anything else, just like `make -C`) [19:20:10] This would be more general, but we don't seem to lack permissions to use it: ``` [19:20:11] $ ssh login.toolforge.org become commons-upload-map -D commons-upload-map git pull [19:20:13] sudo: you are not permitted to use the -D option with /bin/bash``` [19:21:05] hm. try adding a `--` after `become commons-upload-map`? [19:21:19] How do you write codes like this? (re @tuukkahastrup: This would be more general, but we seem to lack permissions to use it: $ ssh login.toolforge.org become commons-upload-map -D co...) [19:21:49] oh, no, you put the option before `git`, that’s not going to work [19:21:55] (also you turned `-C` into `-D`?) [19:22:28] ah, now I see what you mean, sudo’s `-D` is like git’s `-C` [19:22:42] yeah, bit strange that the security policy blocks it, but 🤷 [19:27:58] I guess it is [19:27:59] ``` [19:28:01] Markdown code``` [19:28:02] (re @WoozeWiki: How do you write codes like this?) [19:31:08] Three backticks, if that's what you're asking (re @WoozeWiki: How do you write codes like this?) [19:33:21] (keep in mind that this channel is bridged to IRC, so for code snippets longer than a few lines it’s better to use an external paste service like https://paste.toolforge.org/ and link to that) [19:37:05] I asked this. Thank you :) (re @tuukkahastrup: Three backticks, if that's what you're asking)