摘要:
python安装 1.安装包下载 https://repo.huaweicloud.com/python/ 2.配置镜像源 windows路径:C:\Users<UserName>\pip\pip.ini linux路径: ~/.pip/pip.conf 如果安装完没有该文件,在资源管理器的地址栏输 阅读全文
摘要:
python运算符 1.数学运算符 常见+,-,*,/,%,//(地板除),** print(10 + 20) print(10/4) # 2 print(10//4) # 向上取整 3 print(2 ** 3) #2的三次方 number = 10 number = number + 1 pri 阅读全文
摘要:
python的输出语句 1.支持双引号、单引号、三引号 print("hello world") print('hello python') print("""Linux windows MacOS""") print('''Nginx Httpd Tomcat''') print("This is 阅读全文
摘要:
Typora同步到博客园 python安装 1.python安装包下载 https://www.python.org/downloads/windows/ 2.python安装 参考:win10-pyton安装 3.克隆代码 git clone git@github.com:dongfanger/p 阅读全文
摘要:
Python离线安装第三方包 1.通过pip下载安装包,然后在其他机器上安装 python -m pip download test==1.3.5 // 安装的库名为test,版本为1.3.5 python -m pip install --no-index --find-links=./test/ 阅读全文
摘要:
不同操作系统结束符CRLF转LF 1.下载dos2unix https://waterlan.home.xs4all.nl/dos2unix/dos2unix-7.4.1-win64.zip https://waterlan.home.xs4all.nl/dos2unix.html#UNIX2DOS 阅读全文
摘要:
python连接consul 1. consul的KV操作 #!/usr/bin/python # -*- coding: utf-8 -*- # pip install python-consul import consul class Consul(object): def __init__(s 阅读全文
摘要:
shell读取config.ini文件 该脚本需要三个参数,第一个为文件名,第二个为章节名称,第三个为字段名称 #!/bin/bash iniFile=$1 section=$2 option=$3 function readInIfile() { iniFile=$1 section=$2 opt 阅读全文
摘要:
golang FastHttp 使用 1. 路由处理 package main import ( "fmt" "github.com/buaazp/fasthttprouter" "github.com/valyala/fasthttp" "log" ) func main() { // 创建路由 阅读全文
摘要:
apt下载离线安装包 1.查看依赖 apt-cache depend <package name> 2.下载依赖包 apt-get install dependpackname –reinstall -d xxx #有些包名中有<>符号,用tr将其删除 sudo apt-get install -- 阅读全文