Committed by cron-git from wodemacookdeAir.lan.yimian.xyz

master
boyao1999 4 years ago
parent ae72c384bc
commit e4f2b4c74e
  1. 1
      README.md
  2. 2
      node_modules/cron-git/LICENSE
  3. 8
      node_modules/cron-git/index.js
  4. 3
      node_modules/cron-git/ini.sh
  5. 12
      node_modules/cron-git/package.json
  6. 2
      node_modules/cron-git/test.js
  7. 6
      package-lock.json

@ -1 +1,2 @@
# FDC

2
node_modules/cron-git/LICENSE generated vendored

@ -186,7 +186,7 @@
same "printed page" as the copyright notice for easier
identification within third-party archives.
Copyright [yyyy] [name of copyright owner]
Copyright [2020] [iotcat]
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.

8
node_modules/cron-git/index.js generated vendored

@ -8,7 +8,7 @@ module.exports = function(o_params){
/* factory mode */
var o = {
dir: __dirname,
dir: process.cwd(),
debug: false,
allowNotice: true,
pull: (params, callback, err_callback) => pull(params, callback, err_callback),
@ -21,6 +21,8 @@ module.exports = function(o_params){
/* merge params */
Object.assign(o, o_params);
/* log dir */
console.log(new Date() + ' - cron-git: At dir::' + o.dir);
/* modules import */
const cron = require('node-schedule');
@ -34,7 +36,7 @@ module.exports = function(o_params){
branch: 'master'
},
add: {
path: './*'
path: o.dir
},
commit: {
message: "Committed by cron-git from "+ require('os').hostname()
@ -80,7 +82,7 @@ module.exports = function(o_params){
var push = function(params_user, callback){
var params = {
add: {
path: './*'
path: o.dir
},
commit: {
message: "Committed by cron-git from "+ require('os').hostname()

3
node_modules/cron-git/ini.sh generated vendored

@ -1,2 +1,5 @@
git config credential.helper store
git pull
git add . -A
git commit -m "init from cron-git"
git push

@ -1,8 +1,8 @@
{
"_from": "cron-git",
"_id": "cron-git@1.0.0",
"_id": "cron-git@1.0.5",
"_inBundle": false,
"_integrity": "sha512-DMfZWhvaDtuxxWXew+A+kgED0tRzKw5qEQsN4NSoV1fEf5Gn3+JJZ7LS1NKzX3tsgUvrmyr/KZs198u3/CtIVw==",
"_integrity": "sha512-JQMQREUgtz38mG3kuSkV5XKKVGVUdCBgRjZa+CHrzv0ndydMNeUEMdg5WVt2Y7B14how44ptIpN2K5rXtQOJUA==",
"_location": "/cron-git",
"_phantomChildren": {},
"_requested": {
@ -19,10 +19,10 @@
"#USER",
"/"
],
"_resolved": "https://registry.npmjs.org/cron-git/-/cron-git-1.0.0.tgz",
"_shasum": "c523f5138274c08a7cc0e191aa8b04c78b9d8e99",
"_resolved": "https://registry.npmjs.org/cron-git/-/cron-git-1.0.5.tgz",
"_shasum": "2cfdeeaee5d6ef2bd9515f1eeab75f90fbc91431",
"_spec": "cron-git",
"_where": "E:\\cloud\\OneDrive\\git\\fdc",
"_where": "/Users/wodemacbook/Desktop/fdc",
"author": {
"name": "iotcat"
},
@ -52,5 +52,5 @@
"scripts": {
"test": "node test.js"
},
"version": "1.0.0"
"version": "1.0.5"
}

2
node_modules/cron-git/test.js generated vendored

@ -1,4 +1,4 @@
const crongit = require('./index.js')();
//crongit.pull({}, ()=>{console.log('good')}, ()=>{console.log('bed')});
crongit.schedule("10 * * * * *", ()=>console.log('test ok!!!\nuse Ctrl+C to exit!!'), ()=>console.log('pull err err err err!!!!'));
crongit.schedule("*/10 * * * * *", ()=>console.log('test ok!!!\nuse Ctrl+C to exit!!'), ()=>console.log('pull err err err err!!!!'));

6
package-lock.json generated

@ -3,9 +3,9 @@
"lockfileVersion": 1,
"dependencies": {
"cron-git": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/cron-git/-/cron-git-1.0.0.tgz",
"integrity": "sha512-DMfZWhvaDtuxxWXew+A+kgED0tRzKw5qEQsN4NSoV1fEf5Gn3+JJZ7LS1NKzX3tsgUvrmyr/KZs198u3/CtIVw==",
"version": "1.0.5",
"resolved": "https://registry.npmjs.org/cron-git/-/cron-git-1.0.5.tgz",
"integrity": "sha512-JQMQREUgtz38mG3kuSkV5XKKVGVUdCBgRjZa+CHrzv0ndydMNeUEMdg5WVt2Y7B14how44ptIpN2K5rXtQOJUA==",
"requires": {
"node-schedule": "^1.3.2",
"os": "^0.1.1",

Loading…
Cancel
Save