自动部署工具 WebhookForCoding

码农软件 · 软件分类 · 项目构建 · 2019-11-15 16:29:49

软件介绍

### 简介

本项目用于 coding.net 的 WebHook, 自动让服务器拉取最新代码.

 

### 注释预览(局部)

````php
/**
 * Master Project Webhook.(for coding.net)
 *
 * 约定:
 *
 *  如果项目目录是 /home/wwwroot/Discuz 
 *  那么你应该建一个 Discuz.master.php , 这里约定这个文件名前缀就是项目目录名.
 *      ( 主要为了一目了然, 定义好一个项目的WebHook文件后, 其余项目与之区别仅在于文件名. )
 *      ( 后缀并不要求, 这里是为了与 Discuz.develop.php 区分. )
 *  编辑 Discuz.master.php 加入如下code部分.
 *
 * 
 *  include('./src/autoload.php');
 *  (new \WebHook\PullMaster('/home/wwwroot', 9981, 'log.txt')); // 对应类中三个属性.
 *  // Ok, 在网页端指定 Discuz.master.php 即可.
 * 
 *
 * @farwish
 */
````

 

### 实际用法

`Discuz.master.php`

````php

include('./webhookForCoding/src/autoload.php');

( new \WebHook\PullMaster('/www/web', 8090) );

````

`Discuz.develop.php`

````php

include('./webhookForCoding/src/autoload.php');

( new \WebHook\PullDevelop('/www/web', 8090) );

````

 

### 最后设置

在 coding 项目 '设置' 里的 'WebHook' 项中 指定地址 和 token.

举例:  

alconSeek 项目的 master 分支就设置为 your_ip/alconSeek.master.php  

alconSeek 项目的 develop 分支就设置为 your_ip/alconSeek.develop.php  

discuz 项目的 master 分支就设置为 your_ip/discuz.master.php  

discuz 项目的 develop 分支就设置为 your_ip/discuz.develop.php 

 

本文地址:https://www.codercto.com/soft/d/19054.html

Introduction to Computer Science Using Python

Introduction to Computer Science Using Python

Dierbach, Charles / 2012-12 / $ 133.62

Introduction to Computer Science Using Python: A Computational Problem-Solving Focus introduces students to programming and computational problem-solving via a back-to-basics, step-by-step, objects-la......一起来看看 《Introduction to Computer Science Using Python》 这本书的介绍吧!

在线进制转换器
在线进制转换器

各进制数互转换器

正则表达式在线测试
正则表达式在线测试

正则表达式在线测试

RGB CMYK 转换工具
RGB CMYK 转换工具

RGB CMYK 互转工具