svg_png
#!/usr/bin/env python
#-*- encoding=UTF-8 -*-
from __future__ import print_function
import sys
import random
import string
import os
random.seed(1)
letters = string.ascii_letters
numbers = ''.join([str(i) for i in range(10)])
seed = letters + numbers
sudo apt-get install python-cairosvg
sudo pip install cairosvg
for i in range(1,101):
passwd = ''.join(random.sample(seed,18))
passwd = passwd + str(i)
print(passwd)
#!/usr/bin/env python
#-*- encoding=UTF-8 -*-
from __future__ import print_function
import click
@click.command()
@click.argument("inputlist")
@click.argument("svgfile")
def account_generate(inputlist,svgfile):
svgt = ""
with open(svgfile) as s1:
for s in s1:
svgt += s
i = 0
with open(inputlist) as fin:
for line in fin:
i = i+1
c1 = line.strip()
svgp = open("GFK_vip"+str(i)+".svg","w")
svgtt = svgt.replace("account",c1)
svgp.write(svgtt)
svgp.close()
if __name__ == '__main__':
account_generate()
svg_png的更多相关文章
随机推荐
- ng-if 判断条件中不能 使用变量名字拼接,switch可以
- phpstorm、webstorm配置less编译器
1. node.js 安装包 https://nodejs.org/en/download/ 1) 安装js解析器node.js.直接下一步就ok了. 2) 将npm压缩包解压,找到里面的les ...
- js之数码时钟加随机变色
HTML <!DOCTYPE html> <html lang="en"> <head> <meta charset="UT ...
- huawei机试题目
1/*输入一个字符串,输出这个字符串中单词的字典排序*/ bool cmp(char* a,char* b){ ? true:false; } void sortWord(char* str) { v ...
- 20179223《Linux内核原理与分析》第四周学习笔记
补交第三周作业 完成一个简单的时间片轮转多道程序内核 1.使用实验楼的虚拟机打开shell,用cd LinuxKernel/linux-3.9.4进入linux-3.9.4. 2.执行命令qemu - ...
- MySQL实战 | 04 为什么要使用索引?
原文链接:MySQL实战 | 为什么要使用索引? 用过 MySQL 的应该都知道索引是干啥的吧,应该多少都设置过索引,但是若是问你索引是怎么实现的,你能说上来吗? 索引是什么? MySQL 官方对索引 ...
- iOS 5 :一个UIPageViewController程序示例
原文:http://www.techotopia.com/index.php/An_Example_iOS_5_iPhone_UIPageViewController_Application 在Xco ...
- c# datetime 格式化大全与使用总结
//C# datetime 格式化 DateTime dt = DateTime.Now; Label1.Text = dt.ToString();//2005-11-5 13:21:25 Label ...
- win32鼠标和键盘相关函数
键盘相关函数:http://msdn.microsoft.com/en-us/library/windows/desktop/ms645530%28v=vs.85%29.aspx 鼠标相关函数:htt ...
- ES6中let和const详解
let和var一样也是用来定义变量,不同之处在于let是块级作用域,只在所定义的块级作用域中生效,一个花括号便是一个块级作用域 {var a="我是var定义的";let b=&q ...