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

Резултати

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

Пребарај: #loans

当前筛选 #loans清除筛选
NIDO Russia (НИДО)

@nido_russia · Post #1907 · 02.12.2024 г., 12:42

Russian government to subsidize rural mortgages 📌The funds are provided for the purchase of housing in rural areas. 📌This was said by the Prime Minister Mikhail Mishustin, at a meeting with Deputy Prime Ministers. 📌Additional 5 billion rubles will be allocated to subsidize over 160 thousand loans (under the Rural Mortgage program) that have been concluded in recent years. 📌In July 2023, the government increased the size of the concessional loan under the "Rural mortgage" to 6 million rubles. The initial payment for the program launched in the spring of 2020 is 20%. 📌 A loan in the amount of 100 thousand to 6 million rubles is issued for a period of up to 25 years. The preferential rate of 3% is preserved. #news#russia#nido_russia#rural#housing#loans https://t.me/nido_russia

Venture Village Wall 🦄

@venturevillagewall · Post #3398 · 18.12.2024 г., 12:10

Svakarma Finance Raises $10.4M Svakarma Finance successfully raised $10.40 million in funding on December 13, 2024. For more details, visit their website. #Funding#Finance#Svakarma#Investment#Capital#Startup #2024 #Market#Growth#Innovations#Loans#FinanceTech#DigitalFinance#Fintech#VentureCapital#Equity#FundingRound#FinancialServices#Economy

Venture Village Wall 🦄

@venturevillagewall · Post #3423 · 18.12.2024 г., 12:11

VakıfBank Secures $870M Funding Round VakıfBank has announced a funding round of $870 million, set for November 26, 2024. For more details, visit their official page here. #Funding#VakıfBank#Finance#Investment#FundingRound#Banking#Loans#Capital#Turkey#Business#Economy#November2024#Growth#Market#Assets#InvestmentOpportunities#FinancialServices#InstitutionalInvestors#Debt#Equity

Venture Village Wall 🦄

@venturevillagewall · Post #4071 · 05.02.2025 г., 07:00

NBU Accuses BitCapital of Illegal Lending The National Bank of Ukraine (NBU) has accused the Ukrainian service BitCapital, which issues loans in USDT stablecoins, of providing illegal lending services. Over 700 complaints from citizens cite issues like high interest rates, wrongful charges, aggressive debt collection tactics, and lack of transparency. The service's operations in Ukraine are now banned. Read more here #Ukraine#BitCapital#USDT#Banking#Regulation#Lending#Finance#Crypto#NBU#Loans#ConsumerProtection#Debt#InterestRates#Bans#Complaints#Market#IllegalServices#Transparency#FinanceNews#VC#Crypto