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

TGINSIGHT SIMILAR POSTS

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

Изворен канал @pythonotes · Post #183 · 23 ное.

Python + bash Если вам часто требуется запускать shell команды из Python-кода, какой способ вы используете? Самый низкоуровневый это функция os.system(), либо os.popen(). Рекомендованный способ это subprocess.call(). Но это всё еще достаточно неудобно. Советую обратить своё внимание на очень крутую библиотеку sh. Что она умеет? 🔸 удобный синтаксис вызова команд как функций # os import os os.system("tar cvf demo.tar ~/") # subprocess import subprocess subprocess.call(['tar', 'cvf', 'demo.tar', '~/']) # sh import sh sh.tar('cvf', 'demo.tar', "~/") 🔸 простое создание функции-алиаса для длинной команды fn = sh.lsof.bake('-i', '-P', '-n') output = sh.grep(fn(), 'LISTEN') в этом примере также задействован пайпинг 🔸 удобный вызов команд от sudo with sh.contrib.sudo: print(ls("/root")) Такой запрос спросит пароль. Чтобы это работало нужно соответствующим способом настроить юзера. А вот вариант с вводом пароля через код. password = "secret" sudo = sh.sudo.bake("-S", _in=password+"\n") print(sudo.ls("/root")) Это не все фишки. Больше интересных примеров смотрите в документации. Специально для Windows💀 юзеров #libs#linux

Hashtags

Резултати

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

Пребарај: #daos

当前筛选 #daos清除筛选
Airdropp.io

@airdropp_io · Post #132 · 24.03.2022 г., 19:48

⛱ Airdrop : Ubiquity DAO 🔥 Reward pool: 2,500 USDT 🌐 Website : https://ubq.fi/ 🏅 Winner : 1.000 Random & Top 100 ⭐️ Rating : ⭐️⭐️⭐️⭐️⭐️ 🔗 Airdrop Page : Airdrop Link ===================== 🪧 Tasks :👇 Go to Airdrop Link👆 ✅ Join Telegram group ✅ Follow Twitter ✅ Submit your BEP-20 wallet address 👍🏽Complete all the tasks 📃 Information 🔸As an organization, it is committed to becoming the bank of the #metaverse, while building open-source developer tooling and community management tools to augment the operating efficiency of #DAOs. 📢 Notes: 🔹2 USDT each to 1,000 Random participants 👫5 USDT each to 100 top referrers ⚠️ Disclaimer: Please do your own research before joining to any airdrops project, also airdrop is 100% free. Don't send any fee or penny for receiving airdrop tokens.(DYOR) 🏁 End Date: 30th March, 2022 🚀 Distribution Date: within 25 days after airdrop ends

Venture Village Wall 🦄

@venturevillagewall · Post #3853 · 12.01.2025 г., 04:00

Whale Alerts and Hacked Accounts Update A study by Presto Research shows that large exchange deposits have weak predictive power for price declines, while VC and MM deposits offer slightly better, yet still limited, effectiveness as trading signals. In related news, Foresight Ventures’ X account was hacked, spreading fake AI crypto news, following a similar incident with Litecoin’s account promoting fraudulent tokens. Additionally, the newly launched AICC has reached a market cap of over $130 million, but faces scrutiny over its lack of transparency. Also, Morpho markets have capped positions eligible for migration with deprecated rewards for old markets. Presto ResearchAICC DashboardUsual Update #WhaleAlerts#Crypto#AI#Litecoin#ForesightVentures#AICC#MarketCap#TradingSignals#MorphoMarkets#Security#Hacking#Transparency#DeFi#MM#VC#Blockchain#DAOs#Scammers#Influencers