L.I.B.

Cyame's Personal Blog

0%

字幕组文件服务系统搭建指南

开幕感谢技术支持无敌小火龙晨轩° 救Nginx苦手的菜菜我于水火之中

前言

本指南将尽可能详细地指导小白进行文件服务系统的搭建,并最终可以实现/学会以下内容:

在阅读本指南之前,你需要具备以下基础:

  • Linux系统基础操作
    • 基础文件指令
    • VIM文本编辑
    • APT包管理(推荐使用Ubuntu16.04+)
  • 一颗肯折腾、愿意不断学习和修复错误的心

这些服务虽然是免费开源的,但服务器却不是。因此你还需要具备以下资源:

  • 一台海外网络服务器

    • 价格:$20-100不等/年
    • 推荐服务提供商:搬瓦工
  • 一个域名

    • 价格:¥10-100不等/年
    • 推荐服务提供商:GoDaddy
  • 一个OneDrive(Microsoft Office 365)账号

    强烈推荐世纪互联版,在大陆地区下行可以跑满,其他亚洲区也可以稳定使用

    • 价格:¥500左右/永久
    • 推荐购买渠道:某宝

    一定要问清楚卖家是否支持OneIndex等使用API的服务,买错了可能会导致无法正常配置而吃瘪

    (不要贪便宜去买低价黑卡,产品介绍里可能写不支持,最好能和客服提前交流)

如果你不使用世纪互联版,一是可以使用学生信息去注册(似乎会获得5T免费空间),二是也可以直接去购买国际版账号。

当然个人版也是极好的!(但是本文中许多操作都是为了使用世纪互联而去做的,如果使用国际版的话,可以使用被更广泛使用的OneIndex来替代OLAINDEX,部署方法/步骤更简单(可以参见其他教程)。

  • *一个梯子*
  • 一台网速尚可的个人电脑
  • 一个SSH链接工具
    • 价格:免费/有一些付费的但没必要
    • 推荐软件:MobaXTerm(Windows)/Terminus(Mac)

当然,你可以先阅读本指南了解全部流程后再决定是否购入。关于VPS服务器等一系列资源,网上都有各类充分详尽的教程,因此如何配置DNS解析,如何做CDN,如何购买服务器刷系统、备份镜像等内容不会再本指南中过度展开。

上述推荐服务商仅为本教程所使用的服务商,目前已稳定运行半年以上,本身不存在推广没有恰饭。如果不想对比其他教程使用其他服务商,想阅读本指南一步到位,那还请使用相似的系统方便操作。

敬告

由于网络服务商/域名提供商/(尤其是)网盘存储提供商可能存在跑路情况(泥给路达哟.gif) 本指南不会对所推荐网络服务的稳定性进行任何承诺和担保!如出现任何情况,请自行妥善处理!域名过期了换个域名和SSL证书,服务器跑路了推倒重来一遍,网盘跑路了…wdnmd文件都没了,那还是看情况找个NAS或者稳定的云服务器服务就好;当然有能力维权的话也请维护自己正当权利!

本指南所涉及内容均为爱好者自建行为,未参考地方法律相关条款。请不要使用本服务进行违法犯罪活动(商业行为请自行确认并依法备案),所产生的法律风险本文作者概不负责。

本指南遵循MIT License,保留署名权。禁止一切未标明出处和作者的转载,对于侵权行为保留一切法律追责权利。请周知!

环境配置

请确认您已具备前文中所需条件方可开始操作

配置DNS解析

与其他的教程不同,我推荐先进行DNS解析的配置(主要原因在于解析的生效需要一段时间。虽然GoDaddy生效较快,基本2-5分钟就可以,但不同的域名服务商生效时间不同,可能需要30分钟甚至更长时间)。

购买域名

  • 注册一个账户(记得配置一个有效邮箱方便找回)

  • 点击域名注册

    image-20200825143008462

  • 搜索想要的域名(无需后缀)

    例如搜索myddsite,得到以下结果:image-20200825143138087一般选择最便宜的即可(.xyz的域名通常最便宜,如果没有什么刚需建议找价格合适的就可,解析速度体感上区别不大)

  • 付款(支持支付宝)

    之后加入购物车进行购买即可,选择一年即可。

    image-20200825143534573

    注意:可能会有绑定一些安全服务或者建站服务,这里完全不需要,可以直接取消掉…一般来说只要域名够长,最多30块钱以内就可以搞定。

    image-20200825143631577

    确认无误后点击结账即可,支持支付宝!

    (当然这个我没买,所以之后的域名会部分打码,请理解!)

打开DNS解析配置页

登录后点击右上角的用户名,从下拉菜单中打开我的产品

image-20200825143850580

可以看到自己所购买的域名:

image-20200825144019224

点击DNS,进入DNS配置界面:

image-20200825144244812

配置A域名解析

DNS解析记录我们需要了解两种即可:CNAME和A。

  • A是名访问,即给服务器的IP地址命名。图中@即是指,如果直接在浏览器中输入myddpoint.xyz的话,会请求中的IP。

  • CNAME有点类似于重定向,是使用一个域名指向另一个域名的方法。图中的www指的是,访问www.myddpoint.xyzmyddpoint.xyz是等价的(会指向myddpoint.xyz)。

因此我们可以点击右下角的添加,添加一个A类型的解析:

image-20200825145410566

主机即为名称,或者可以成为次级域名指向即为服务主机(的IP)。

例:假设这里主机填写be,指向填写2.3.4.5。那么当我们在浏览器中访问be.myddpoint.xyz时,会访问2.3.4.5的80端口(HTTP)或者443端口(HTTPS),具体取决于后文中是否配置了SSL证书以及NGINX配置。这里我们可以模糊地理解为给2.3.4.5起名为be.myddpoint.xyz

在这里,你需要申请两个次级域名,分别对应上述OLAINDEXCloudreve的服务。

初始化服务器环境

购买服务器

重建系统

使用SSH连接

更新APT镜像

在控制台中运行

1
apt update

运行一键安装脚本

请按顺序进行运行,有部分软件依赖由前一步携带安装

  • 安装YouTube-DL和OneDriveUploader

    1
    apt install curl
    1
    curl https://raw.githubusercontent.com/lovezzzxxx/liverecord/master/install.sh | bash
    1
    source ~/.bashrc
  • 下载Cloudreve服务

    请下载到非/root/(~)目录下,并在下载解压后使用chmod +777 <解压可执行文件>进行授权。

    1
     
  • 下载OLAINDEX服务

    请下载到非/root/(~)目录下,并在下载解压后使用chmod +777 <解压文件夹>进行授权。

    1
     
  • 一键NGINX+PHP脚本(来自ONEINSTACK)

    1
    wget -c http://mirrors.linuxeye.com/oneinstack-full.tar.gz && tar xzf oneinstack-full.tar.gz && ./oneinstack/install.sh --nginx_option 1 --php_option 8 --phpcache_option 1 --reboot

    运行后会自动断开SSH连接并重启,请稍后

安装配置环境&检测

OneDrive服务搭建

启动WEB服务

申请SSL证书

使用运行脚本时下载的Oneinstack进行一键SSL申请+配置(默认应该在~/oneinstack/

运行其中的vhost.sh

1
/root/oneinstack/vhost.sh

配置NGINX

但是vhost配置的服务是给静态网站使用的,本次需要配置的网站一个为本地服务,另一个为伪静态网站,需要另行配置。

因此在分别添加vhost服务后,需要对/usr/local/nginx/conf/vhost/中网站对应服务的配置文件作出修改,在此给出范例:

  • OLAINDEX

    1
     
  • Cloudreve

    1
     

重启NGINX服务

1
service nginx restart

初始化文件系统

YouTube-DL + OneDriveUploader

OLAINDEX

Cloudreve

用户使用指南

Preface 前言

About Documentation 关于本文档

It’s a personal edition of Aegisub Override Tags Documentation. This document is helpful to amateur and experienced, and also detailed enough for novice to build a comprehension to the tags. Also, if you are an expert, the documents will also have a great help in understanding why it is so. So you won’t have to spend so many time in debugging or reviewing the official documents everytime you use them.

Before you read, I’d like to state that the tag is highly associated with computer programming, though it’s possible to be used without any programming skills. Thus if there’s anything caught you stucked, please skip it. Every paragraph is kind of independent that a questioning paragraph won’t influence the understanding of other parts.

  • If you know nothing about programming and are a completely freshman, I highly recommand you to read Official Documents and watch some Tutorial videoes first.
  • If you are a programmer or have some basic knowlege in programming, it will be easy for you to understand. So you only need to take a quick look of this document and use the API once you need to have a look-up.
  • If you are an experienced subtitle producer with little understanding in programming area, congratulations! This tutorial is tailored for you! Or if you are already an expert in Aegisub and want to sharpen your comprehension, this tutorial will also leave a benefit for you.

Thus, though I will include some tables like API as well, the introduction will be with some comprehensive samples and combining skills. So please make sure you already have a basic knowledge of Aegisub and those tags before your reading, which would give you a better experience.

In conclusion, this documentation is focused on theoric comprehension, customized for those who have basic knowledge of Aegisub, and interest in learning more about tags and related programming theories.


这是一篇个人版Aegisub特效标签文档。本文档适合于爱好者熟练使用者阅读,并且内含了大量详细说明以便初学者对标签有一个更好的理解。当然,如果你已经非常熟悉Aegisub,这篇文档也能帮你理解(一些写法和现象)为什么会是这样。这样你在每次使用时就不必花费大量时间来进行调试和翻阅文档。

在阅读之前,我想先声明特效标签与编程是密切相关的,即便不需要编程基础也能正常使用。因此如果有不理解的部分请直接略过,每段内容相对独立,某一部分的问题不会影响其他内容的理解。

  • 如果你是一个完全不了解编程(并且还不太会使用Aegisub)的纯萌新,我强烈推荐你先去阅读官方文档并且观看一些教学视频
  • 如果你是一位程序工程师或者有一定的编程知识,那么你会非常快地理解本文档内容。因此你可以快速阅读本文档,之后查阅API文档即可。
  • 如果你是一位使用Aegisub非常熟练的轴Man,但你对于相关编程知识不甚了解。那么恭喜你!本文档就是为你量身定做的!或者如果你已经是一位老轴师并想加深自己对Aegisub的理解,这篇文档一样对你会有帮助。

因此,虽然我也会在其中包含一些API表格,但本文档中会有很多易于理解的实例和组合使用技巧。因此请确保自己对Aegisub有基础的了解以获得更好的阅读体验。

总之,本文档专注于概念理解,适合对Aegisub有基本了解,并对特效标签及相关编程知识感兴趣的使用者阅读。

About Notation 关于注记

  • This documentation have both Chinese and English version together. Though the explanation styles and words will be different, the concept and theories are the same. Besides, the exteral link will be different (according to the language). It will be divided into two posts after completely finish. There are three major reason for two version: Firstly, it’s aimed to be accurate and no ambiguity; Secondly, it’s used to help the writer to manage the documenting thread to be clear and perfect, it’s also a training of translating skills. Third, it’s looking forward to more subtitle amateurs to take a look of it, though whether it’s helpful is on you, the readers.
  • The document have some graphs using Mermaid to create, which could be displayed in Typora. And as follows, there’s a web picture using SMMS as photobed, with the auto-upload service powered by PicGo. Thus, you have no need to read the “rediculous” code blocks, but may help if the picture is not loaded currectly.
  • The documentation will mainly use two kinds of notation form as follow
    • <some-notes>: e.g.\fs<font-size>, please replace the full text including <> with the content, like \fs80. In contrast with the official documentation, the note will used full natural languages. Though it will be complex comparing to the symbols, but will be more comprehensive.
    • : Within every blocks, there will be a api table at the top, with examples and detailed explanation following at most cases. Because of the relationship and contrast will be complex, some significant notes will be also in the tables.

  • 本文使用中英双语编写,两边给出的解释和说明可能会有略微不同,但整体概念无差异。两侧的相关外部链接也会有差别。待编写完成并进行完善后会拆分为中英两版。写两版的主要理由一是在于为了规范表达消除二义性,二是为了笔者个人进行逻辑梳理和对译训练,三是希望能有海外和更多的字幕制作爱好者能够看到这篇文档,当然是否有帮助要交给各位来评判。

  • 本文档配图使用Mermaid语法编写,Markdown文档自身可以在Typora等软件内查看。网页版图片会使SMMS作为图床,采用PicGo进行上传部署。因此中间的代码块无需阅读,在无法加载图片的时候可以参考。

  • 本文档将主要使用以下两种注记方式

    • <此处填入内容>:例如\fs<字体大小>,在使用时请在<>内填入对应的内容,如\fs80。与官方文档不同的是,本文档中的内容注记将全部使用自然语言进行表示,因此相较于精简的符号表示会略显繁琐,但更易于理解。

    • <API表格>:在每条标签的介绍前均会给出一个API表格用于说明其用法,绝大多数情况下会在后文中有用例及使用说明。由于标签之间的相关和相斥(二选一生效)关系比较复杂,因此重要的描述也会在表格内进行。

Introduction 绪论

What is “Override”? 何为”重载”?

Override is a programming terminology, which originally means the sub class rewrite the function in the superclass or interface, so that every instance(object) under the sub class, would prefer to excute the override funtion, instead of the original function declared in the super class. Actually, you don’t have to know it so well before your journey in using override tags. In fact, to be simple but not accurate, we can state that each style of every subtitle lines (especailly refers to dialogue), have a 3-layer struture of its presentation in vision.

1
2
3
4
5
graph TD;

A[Word] --> |+/bandled with|B[Font Style]
B --> |+/A special kind of|C[Override Tags]
C --> |Override|B

重载是一个编程术语,原意为子类重写了父类或接口中的函数,因此对于子类的实例(对象),会运行重载后的函数,而非原函数。实际上,你不需要完全理解它。实际上,打个不太准确的比方,我们可以说任何一行中的样式,在显示时存在如下的3层结构。

注:英文中特效标签被称为重载标签(Override Tags)而非特殊效果标签(Effect Tags)

1
2
3
4
5
graph TD;

A[字幕] --> |+/绑定|B[样式]
B --> |+/特殊形式|C[特效标签]
C --> |重载|B
截屏2020-07-17 下午2.17.10

Break 空白

Line Autobreaking Style 自动换行模式

Interpretation 名词解释

Color Notation 颜色注记

A color notation is used to present a RGB color, and in Aegisub, it should be written as &H<6-digits_color_code>&. A 6-digit code, which always be with a prefix of #, is a standard code to discribe any of the RGB color, which is widely used in web, Photoshop and etc. It is in a format of RRGGBB which has a couple of hexical numbers used for a 8-bit color discription.

RRGGBBmeans we use 2-digits of hexical humbers to discribe a kind of color(Red, Green or Blue), then combine them together with each color in the range of 0-255, which actually fit in the range of a 8-bit RGB color (8 digits in binary).

For instance, a color code F3E109means that Red = F3(Hex) = 243(Dec), Green = E1(Hex) = 225(Dec), Blue = 09(Hex) = 9(Dec), represent a RGB color of (R,G,B) = (243,225,9), it’s gold!

In most case, color notation is capital insensitive, which means FFACDBandffacdbare actually the same.

Note: Though unstandard color code still work, such as &HFF0000&(Red) could be written as &FF0000&,FF0000,Hffand evenff, I personally not recommand for the abbreviated form because it’s difficult for others to tell.

As we can see, Aegisub’s parser has some interesting patterns:

  • Weakly Typed Language

    The tag parser only parse the value it could recognize, but not should accept. Because of that, it has a weak grammar and allows all kinds of grammar mistakes without runtime error, for it will automatically convert it into nil(NULL/None/Void/Invaild) or 0(No Value/0).

    So if you declared the color like &H#&, it will give a color of black, which refers to 0.

  • Left-Association(Priority)

    In another word, it will read from left to right, so the code on the right share higher priority than the left (because it will overwrite the attribute when it is parsed). So that’s why FF equals to FF0000 instead of 0000FF. It’s the same for inline key words and override tags.

    If you declared twice, it will accept the last(right) one instead of the first(left) one.

  • 1-Parameter Inclusity

    Although it’s hard for those programming freshman to comprehend, it’s neccessary to tell somthing about parameter so that it will be easier for amateurs to remember those format. The law is that every tag has only one parameter, or parameter tuple(list). So for those tags that need multi-domains, we need a () to make them together as a tuple, otherwise without it.

    So a simple color tag should be like \1c&HFF0000&without(), or it will return black as 0, but the various color need to be declared as \1vc(&HFF0000&,&HFF0000&,&HFF0000&,&HFF0000&).


颜色注记是一种表示颜色的方式。在Aegisub中,它被表示为&H<6位颜色代码>&。6位颜色代码是一种描述RGB颜色的标准方式,在网页、Photoshop中都有广泛的使用。它的形式是由红红绿绿蓝蓝用一对16进制数字用以描述8位色彩。

红红绿绿蓝蓝实际上是我们用2位16进制数表示一种原色(红/绿/蓝),然后将他们组合起来。每种颜色的范围都是0-255,正好对应8位RGB颜色的范围(256为2的8次幂)。

例如,一个颜色代码F3E109表示红色=F3(十六进制)=243(十进制),绿色=E1(十六进制)=225(十进制),蓝色=09(十六进制)=9(十进制),表示一个(R,G,B)=(243,225,9)的RGB颜色,是金色!

在大多数场景下,颜色注记都是大小写不敏感(不区分大小写)的,这意味着FFACDBffacdb是完全等价的。

注意:虽然非标准颜色注记一样能被识别,例如&HFF0000(红色)可以被写作&FF0000&FF0000Hff甚至是ff,但是我个人并不推荐简写形式,这会降低代码可读性。

因此我们可以看到,Aegisub标签语法有一些有趣的特性:

  • 弱类型语法

    标签语法检测器会识别它可以识别的而非应该接受的。因此,它是一种包容各种语法错误而不会产生运行错误的弱类型语法。因为它会自动地将无法识别的部分转换为否(空/无/未指定/无效)或者0(空值/值为0)

    注:关于空/无/未指定(NULL/None/Void),均为其他编程语言中对于空对象/变量的保留字(描述用的语法)。

    因此如果你声明&HF#&,他会返回一个黑色,也就是0值(000000)。

  • 左结合(优先)性

    换种方式说,语法分析器会从左向右读,因此左边的标签往往会被右边覆盖(右边的优先级更高)。这也是为什么FF会被认为与FF0000等价而不是0000FF。对于标签内和标签间均是如此。

    如果你重复声明两种颜色,那么它会取右边(后面)的颜色而非左边(前面)的颜色进行显示。

  • 单参数性

    虽然对于编程新人来说可能难以理解,但是讲一些关于参数的事情还是有必要的。这能让新人更容易记住语法的格式。规则是对于任何一个标签只会有一个参数,或一个参数表(参数元组)。因此对于那些需要很多输入的标签,我们需要用一组()括起来,使他们形成一个元组,否则不需要。

    所以一个单色标签应该被写作\1c&HFF0000&(无括号),否则就会被转换为0(黑色)。但是渐变颜色则需要被声明为 \1vc(&HFF0000&,&HFF0000&,&HFF0000&,&HFF0000&)

Library 库

Tag Scope 标签作用域

Pa

Parameter 参数

  • Options

    • Effect Scope 效果作用域
    • Align 对齐方式
  • Size

  • Color

  • Time

  • Position

  • Angle

  • On/Off

  • Other Factor

Elements 元素

Size 大小

Font Size 字体大小

Code \fs<font_size>
Discription Inline modifier of font’s dot size.
Fx Scope Syllable
Library Affiliated VSFilter

The dot size contributes to the frame size. For instance, a font in size of 80 in 1080P video script could be as large as the one in size of 60 whose script is in 720P size. Besides, the size is limited which means it could not be extremely large.

Element Size 元素大小

Code \fsc<size(%)>
Discription Scale of line element.
Fx Scope Syllable
Library Affiliated VSFilterMod

Color 颜色

If you forget about color_notation, you can return to paragraph Color Notation before read.

Simple Color 单色

Code \<scope>c<color>
Discription Fill with color in a particular scope.
Fx Scope Syllable
Library Affiliated VSFilterMod

Various Color 渐变色

Code \<scope>vc<left-top-color,right-top-Color,left-bottom-Color,right-bottom-Color>
Discription Fill with 4-angle-controlled linear gradient color in a particular scope.
Fx Scope Syllable
Library Affiliated VSFilterMod

Font Style 字体样式

Border Width 描边宽度

Code \bord<width>
Discription Border width of the font.
Fx Scope Syllable
Library Affiliated VSFilter

Shadow Distance 阴影距离

Code \shad<distance>
Discription The distance(size) of the font’s shadow.
Fx Scope Syllable
Library Affiliated VSFilter

Blur Edge 模糊边缘

Simple Blur 简单模糊
Code \b<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter
Gaussian Blur 高斯模糊
Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Spacing 字符间距

  • code: ``

Font Family 字体

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

-code: \fn<font-family name>

Shape(AssDraw) 形状(绘图)

Draw Activation 开启绘图

  • code: \p<0/1>

    Code \be<on/off>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter
    ### ASSDraw Code 绘图代码

Attribute 属性

Alpha 不透明度

Code \alpha<color>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Line Alignment 对齐方式

  • Code \an<align>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter
    ### Rotation 旋转
    #### Common Rotation (Z-axis Rotation) 平面旋转(Z轴旋转)
  • code: \frz<angle>

  • Code \frz<angle>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter

X-axis Rotation (Fake 3D) X轴旋转(伪3D)

  • code: \frx<angle>

  • Code \frx<angle>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter

Y-axis Rotation (Fake 3D) Y轴旋转(伪3D)

  • code: \fry<angle>

  • Code \fry<angle>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter

Mask 遮罩

Clip 矩形遮罩

Code \clip(<left-top-point-postion>,<right-bottom-point-postion>)
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Bezier Clip 贝塞尔遮罩

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Position 位置

Code \pos(<position>)
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Style Reset 重置样式

Code \r
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Motion 动画

Keyframe Animation 关键帧动画

Code \t(<start-timestamp(frame)>,<end-timestamp(frame)>,<corresponding-effects>)
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Fade(Fade-in&out) 渐变(淡入淡出)

Simple Fade 简单渐变

  • code: \fad(intime_range,outtime_range)

  • Code \fad(<fade-in-animation-length>,<fade-out-animation-length>)
    Discription Simple Fade-in and Fade-out Effect.
    Fx Scope Line
    Library Affiliated VSFilter

Complex Fade 复杂渐变

  • code: \fade(alpha_at_first, alpha_in_the_middle, alpha_before_end, timestamp_at_the_tail_of_*first*,time_at_the_head_of_the_*middle*,time_at_the_tail_of_the_*middle*,time_at_the_head_of_*end*)

  • Code \be<on/off>
    Discription With/Without blur effect.
    Fx Scope Syllable
    Library Affiliated VSFilter
    ### Movement 移动

Move-in-line

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Complex Movement

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Karaoke 卡拉OK

Key Time

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Key with Fade

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Conclusion

Code \be<on/off>
Discription With/Without blur effect.
Fx Scope Syllable
Library Affiliated VSFilter

Reference 参考资料

综述

关于Git

关于GitHub

GitHub Pages

Marketplace

  • Level4

精通

预研,设计,开发,debug,测试经理

1)具备模块子系统的架构设计能力;
2)能深入理解子系统对整体架构的影响;
3)具备资深的模块设计和开发能力以及评审能力;
4)具备专业的文档输出能力;
5)具备测试架构设计以及用例设计的指导能力;
6)精通模块关键性能指标以及相关标准;
7)熟悉业内先进技术以及演进路线并具备相应的战略判断力;
8)具备与客户的深入沟通以及客户导向引导能力;
9)能组织并决策子系统内部的架构设计评审以及开发评审;
10)及时发现并提出基于过程改进的建设性建议和措施;

  • Level3

熟练

设计,开发,debug,测试leader

1)具备深入的模块设计和开发能力以及设计评审能力;
2)具备专业的文档输出能力;
3)熟悉模块子系统的架构以及外部接口;
4)具备测试用例设计的指导能力;
5)了解模块关键性能指标以及相关标准;
6)能组织子系统内部的开发和测试用例评审;
7)能提出过程优化建议以及改进措施;

  • Level2

有经验

开发,debug,测试sub leader

1)具备模块的开发能力并能独立完成工作;
2)具备基本的文档撰写能力;
3)具备测试用例设计指导能力;
4)具备模块外部接口的相关知识和基本的debug能力;
5)熟悉开发环境以及相应的开发、提交、评审、发布流程;

  • Level1

入门

开发,debug(需要有人指导),按照测试用例测试

1)具备基本的模块知识以及模块外部接口知识,并可在他人指导下完成工作;
2)具备模块相应的测试知识;
3)熟悉开发环境以及开发提交、评审流程;

Lua Grammar

Data Type

Basic Operator

Loop

Condition

Function

Regular Expression

正则表达式
Form:用/Re/包围

? -> 0,一个字符

  • -> 0,1,多个字符
    ^ -> 字符串起始位置
    $ -> 字符串结束位置
    [0-9]单个数字
    [a-z]单个字母
    {3,15}3~15个字符
  • ->前一个字符出现1+次
  • ->前一个字符出现0+次
    ? ->前一个字符出现0,1次

转义
\cx 匹配由x指明的控制字符
\f = \cL = 匹配换页符
\n = \cJ = 匹配换行符
\r = \cM = 匹配回车符
\s = 匹配任何空白字符
\S = 匹配任何非空白字符
\t = \cl = 匹配制表符
\v = \cK = 匹配垂直制表符

$ 字符串结尾
() 子表达式首尾

  • 0+
  • 1+
    . 除了换行\n以外任何单字符
    [] 表达式首尾
    ? 0或1次
    \ 转义符
    ^ 起始位置
    {} 限定符首尾
    | 两项间选择

限定符
{n}匹配n次
{n,}匹配至少n次
{n,m}匹配n~m次

常用组合
.* 单行
.*? 最小单行

定位符
\b 匹配单词边界
\B 匹配非单词边界

优先级
转义>方括号&圆括号>限定符>定位点/序列>或

常用
^[a-zA-Z0-9_]+$ // 所有包含一个以上的字母、数字或下划线的字符串
^[1-9][0-9]*$ // 所有的正整数
^-?[0-9]+$ // 所有的整数
^[-]?[0-9]+(.[0-9]+)?$ // 所有的浮点数
☝[-]?是可选负号的意思