TGTGInsighttelegram intelligenceLIVE / telegram public index
← Python Заметки

TGINSIGHT SIMILAR POSTS

Најди сличен содржај

Изворен канал @pythonotes · Post #411 · 9 фев.

reload_flag="" if [[ -n "${DEBUG}" ]]; then reload_flag="--reload" fi if [[ -n "${WORKER_COUNT}" ]]; then workers=${WORKER_COUNT} else workers=2 fi gunicorn --workers ${workers} \ --bind 0.0.0.0:8000 \ ${reload_flag} main.wsgi Писали такие конструкции чтобы проверить наличие флага и сформировать команду правильно? На самом деле можно сделать тоже самое проще. Для этого используются операторы условной подстановки, доступные в оболочках семейства POSIX. :- для установки значений по умолчанию ${WORKER_COUNT:-2} Если переменная не объявлена, то будет дефолтное значение 2. :+ подставляет указанный текст, если переменная не пуста ${DEBUG:+--reload} Если что-то есть в переменной то распечатается текст после символа +, в противном случае - ничего. Удобно для опциональных флагов, как в нашем примере. Итого наш скрипт может выглядеть так: gunicorn --workers ${WORKER_COUNT:-2} \ --bind 0.0.0.0:8000 \ ${DEBUG:+--reload} main.wsgi Есть еще два оператора. := не только подставить дефолтное значение, но и присвоить его переменной, если она пуста # никаких переменных еще нет VAL1=${VAL2:=hello} # теперь доступны обе echo $VAL1 $VAL2 # hello hello :? остановить выполнение с ошибкой, если переменной нет. echo ${MISS:?is required} bash: MISS: is required Код выхода будет 1. #tricks#linux

Резултати

Пронајдени 24 слични објави

Пребарај: #shanghai

当前筛选 #shanghai清除筛选
SpotOnChain | Announcement

@spotonchain · Post #163 · 12.04.2023 г., 19:24

🚨🚨 A whale, likely BlockTower capital, just moved 5,989 $ETH ($11.4M) to Coinbase, Deribit and Kraken an hour ago. ➡️ The action is right before the #Shanghai upgrade (which is in about 3 hours) ➡️ The whale also moved 2,630 ETH ($5M) two days ago to Coinbase Will we see the dump after #Shanghai🤔🤔? Address link: https://etherscan.io/address/0x43adde52c6c142912662d3e427709db5cac9b811

Hashtags

SpotOnChain | Announcement

@spotonchain · Post #161 · 12.04.2023 г., 02:03

🔥🔥#Shanghai upgrade is less than 24 hours ➡️ It happens at block 194,048 ➡️ Estimated time: 10:30PM UTC 12 Apr 2023 Do check out the important stats in our previous tweet https://twitter.com/spotonchain/status/1643640198222454785?s=20

Hashtags

SpotOnChain | Announcement

@spotonchain · Post #154 · 09.04.2023 г., 03:16

🚨 A whale "peedan.eth" just swapped 627.084K $LDOto 1.46M $CRV ($1.5M) 8 hours ago. ➡️ The average swapping price was $2.4 per $LDO and $1.05 per $CRV ➡️ With this action, he cleared off all of the $LDO right before #Shanghai upgrade 🤔 ➡️ For the above swap, he converted 168K $LDO directly to $CRV and the rest was swapped to $ETH before swapping to $CRV ➡️ Those $LDO was accumulated using 368 $stETH and 467 $WETH (~$1.5M) at $2.4 per $LDO on Apr 02 His Address: 0x509984Bfc0fb24E2d1377CFec224d3AfEc4c341E

Hashtags

SpotOnChain | Announcement

@spotonchain · Post #166 · 14.04.2023 г., 03:28

🌟🌟🌟 Wallet 0xA03D (likely @ambergroup_io) received 500K $LDO at $2.32 (~$1.16M) from #Binance right before #Shanghai upgrade on Apr 12. 💰With the recent pump ($LDO price 🔼 ~11%), the unrealized profit for this trade is $110K. ✅ Amber mostly accumulated $LDO at low (in late 2022) & appears to be strong holder. 👉 More details about Amber’s $LDO trading history and profits: https://twitter.com/spotonchain/status/1646714234468970497

SpotOnChain | Announcement

@spotonchain · Post #150 · 06.04.2023 г., 06:35

🔥 Some VC and KOL recently resumed their $LDO activities ahead of the upcoming #Shanghai upgrade! 🔥 ⭐️Dragonfly Capital kept on moving another 191K $LDO at $2.56 (~$495K) to #Binance 10 hours ago ✅ They used to transfer 2M $LDO to OKX at $2.33 (~$4.67M) on Mar 23 ✅ Their average buying price was at $1.6 ✅ Still hold 20.95M $LDO ~ $53.2M across 4 wallets ⭐️Rune (founder of MakerDao) restarted to swap 153K $LDO for 570 $MKR and 4.2 $WETH 14 hrs ago ✅ No new $LDO were purchased. Just received back 1.2M $LDO that he temporarily moved out to a middle wallet. ✅ The last $LDO-$MKR swapping happened on Mar 17 (19 days ago) Addresses: Dragonfly: 0x7D68a49754c55f1fB410F535f2b82a16f64481b6 RuneKek: 0x0f89D54B02ca570dE82F770D33c7B7Cf7b3C3394

allanesta_film

@allanesta_film · Post #229 · 01.10.2025 г., 19:57

Папоротник 🌿 📎 261 📆 07_2025 🗺 Павлово на Оке, Нижегородская область 📷 Olympus OM-1/ Seikanon MC 28/2.8 🎞 SHANGHAI Color film 400 🧪 C41 📌 iso 400 P.S. привет октябрь #olympusom1 #shanghai

Hayat Estate на выставке в Китае Эти три дня стали невероятно насыщенными: 🤝 Мы встретились с интересными людьми, 💬 Пообщались с партнёрами и посетителями, 🌏 Открыли новые возможности! Шанхай, спасибо за вдохновение и теплый приём! #Shanghai#Выставка2024

SpotOnChain | Announcement

@spotonchain · Post #70 · 01.03.2023 г., 12:14

🔥🔥$RPL may be one of the #LSD narrative leaders amid the #Shanghai upgrade hype! ✅ Backed by @Rocket_Pool, highly decentralized LSD's with 1.9K different nodes. ✅ ​​Reached $1B in TVL in less than 2 yrs ✅ Price x2.4 since 2023 ($19.9 -> $48.4) ✅ Strong early investors & VCs 👉More details: https://twitter.com/spotonchain/status/1630903801099038726

12
ПретходнаСтраница 1 од 2Следна