Project leader Summary
- A, Redis
- Two, Git
- 1. Git project file management
- Project file management steps:
- Project file status change:
- Rollback:
- Branch
- Resolve conflicts
- Branching and Version Management
- Use the rebase
- 2.GitHub
- Three, Vue
A, Redis
1.Redis Introduction
What is
It is a C language development, open source nosql database.
characteristic
- It supports data persistence
- It supports data backup
- More data types
Scenarios
- Cache
- count
- like
- online users
installation
- Ubuntu
- Time
- Windows
Profiles
port 6379 port
16 database number (0-15) Databases
Save 9000. 1: within 900 seconds there is a change in the stored data the bind
the bind 127.0.0.1: default saved locally
daemonize yes: Start Background
Five data types
- string
has set, get, mset, mget, del, strlen, append, incr, decr, incrby, decrby, setrange ( alternatively -), getrange (Get The value range) and the like. - list
have lpush, rpush, lrange, lindex, llen, lpop, lrem ( delete the specified number of the same element), lpop, rpop, lset, ltrim ( taken according to the range and re-assignment), linsert Before / after other methods. - hash
has hset, hget, hmset, hmget, ggetall, hdel, hlen, hexists, hvals / hkeys like. - set unordered collection
have sadd, smembers, sismember, scard (number of elements), srem, srandmember, spop, smove, sdiff, sunion, sinter or the like. - zset ordered set
has zadd, zrange, zrem, zcount, zcard, zrank, zrangebyscore like.
2.Redis and interactive Python
- installation
pip install redis
- connection
redis.Redis(host='',port=6379,db=')
redis.StrictRedis(host='',port=6379,db=')
- Operating
method for different data types with identical or similar redis command.
The master-slave configuration 3.Redis
Reducing the pressure of the main library is written.
- The main arrangement
- Modify the configuration file bind parameters
- Turn on the host service
- From the configuration
- Copy the configuration file
- Modify the configuration file
- Modify the configuration file parameters
- Open service
Two, Git
1. Git project file management
Project file management steps:
- initialization
git init
- Add submitted
git add .
git commit -m 'xxx'
Project file status change:
- Red indicates new or modified files
- Green indicates that the file has been Git to manage
Rollback:
- Back rollback:
git log
git reset --hard 版本号
- Rollback forward
git reflog
git reset --hard 版本号
Branch
- View branch
git branch
- Creating a branch
git branch 分支名
- Switching branch
git checkout 分支名
- Create and switch branch
git checkout -b 分支名
- Branches merge
git merge 分支名
Resolve conflicts
- Manually resolve the
location of the conflict to find and modify. - Tools to solve
beyond compare so on.
Branching and Version Management
- Version of the main branch line
- Development branch development function
Use the rebase
Integration submit records, merge multiple versions, as follows:
git rebase -i [版本号/HEAD~3]
2.GitHub
Code hosting, multiplayer collaborative development, code review and so on.
Three, Vue
The basic use of 1.Vue
- Computed Property
- Binding form
- Custom Components
- Lifecycle Functions
2.Vue-Router
- installation
- use
<html>
<router-link></router-link>
<router-view></router-view>
</html>
<script>
var router = new VueRouter({
orutes:[
{path:'路径',componment:'组件'},
// 动态路由
{path:'路径/:userid',componment:'组件'},
// 匹配404错误
{path:'*',componment:'组件'},
// 路由嵌套
{
path:'路径',
component:"组件',
children:[
{path:'路径',componment:'组件'},
{path:'路径',componment:'组件'},
]
}
]
})
new Vue({
router:router
})
</script>
- Programmatic navigation
new Vue({
el:'#app',
router:router,
methods:{
xxx:function(){
this.$router.push('路径')
}
}
})
3.Vue-Cli
- nvm installation
- npm install
- vue-cli create project
- Definitions and the import component