Skip to content

Commit

Permalink
Merge pull request #1 from 1002946570/main
Browse files Browse the repository at this point in the history
增加github action文件
  • Loading branch information
TrickLin authored Mar 15, 2022
2 parents 5368d37 + 0413543 commit e6aa220
Show file tree
Hide file tree
Showing 3 changed files with 119 additions and 63 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/start.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
# This is a basic workflow to help you get started with Actions

name: CI

# Controls when the workflow will run
on:
# Triggers the workflow on push or pull request events but only for the main branch
push:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
# * is a special character in YAML so you have to quote this string
- cron: '0 0 * * *'

# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:

# A workflow run is made up of one or more jobs that can run sequentially or in parallel
jobs:
# This workflow contains a single job called "build"
build:
# The type of runner that the job will run on
runs-on: ubuntu-latest

# Steps represent a sequence of tasks that will be executed as part of the job
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2

- name: Setup Lua/LuaJIT
# You may pin to the exact commit or the version.
# uses: xpol/setup-lua@84f642e19a1adbad98b74f9e69ab82d1e6b95e3e
uses: xpol/setup-lua@v0.3
with:
# Optional: The target platform (e.g. -A Win32 | x64).
platform: ubuntu,# optional

- name: get data
run: |
curl -O http://bot.kcwiki.moe/luatable/shinkai-ships.lua
curl -O http://bot.kcwiki.moe/luatable/shinkai-items.lua
rm zhikongzhi.txt
# Runs a set of commands using the runners shell
- name: Run lua
run: lua zhikongjisuan.lua

- name: check
run: ls -l

- name: push
uses: actions-go/push@v1
with:
commit-files: zhikongzhi.txt

6 changes: 3 additions & 3 deletions zhikongjisuan.lua
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@ function isReconnaissance(arr1)
end


equipmentData = require("equipment")
shipData = require("ship")
equipmentData = require("shinkai-items")
shipData = require("shinkai-ships")
shipDataTable = shipData.shipDataTable
equipDataTable = equipmentData.equipDataTable
data = {}
Expand All @@ -37,4 +37,4 @@ table.sort(key_table)
local file=io.output("zhikongzhi.txt")
for _,key in pairs(key_table) do
io.write(" [\""..key.."\"] = " .. data[key]..",\n")
end
end
120 changes: 60 additions & 60 deletions zhikongzhi.txt
Original file line number Diff line number Diff line change
@@ -1,60 +1,60 @@
["1505"] = 1,
["1506"] = 1,
["1507"] = 1,
["1509"] = 1,
["1511"] = 1,
["1518"] = 1,
["1519"] = 1,
["1520"] = 1,
["1522"] = 2,
["1527"] = 2,
["1529"] = 2,
["1541"] = 2,
["1543"] = 2,
["1555"] = 1,
["1566"] = 4,
["1567"] = 4,
["1591"] = 1,
["1592"] = 1,
["1594"] = 2,
["1595"] = 2,
["1601"] = 1,
["1602"] = 1,
["1603"] = 2,
["1604"] = 2,
["1659"] = 4,
["1660"] = 4,
["1661"] = 4,
["1662"] = 4,
["1663"] = 4,
["1664"] = 4,
["1684"] = 4,
["1685"] = 4,
["1686"] = 4,
["1687"] = 4,
["1688"] = 4,
["1689"] = 4,
["1705"] = 4,
["1706"] = 4,
["1707"] = 4,
["1790"] = 2,
["1791"] = 2,
["1792"] = 2,
["1793"] = 2,
["1794"] = 2,
["1795"] = 2,
["1796"] = 2,
["1797"] = 2,
["1798"] = 2,
["1862"] = 1,
["1863"] = 4,
["1864"] = 4,
["1895"] = 4,
["1896"] = 4,
["1897"] = 4,
["1898"] = 4,
["1899"] = 4,
["1900"] = 4,
["1901"] = 4,
["1902"] = 4,
["1903"] = 4,
["1505"] = 1,
["1506"] = 1,
["1507"] = 1,
["1509"] = 1,
["1511"] = 1,
["1518"] = 1,
["1519"] = 1,
["1520"] = 1,
["1522"] = 2,
["1527"] = 2,
["1529"] = 2,
["1541"] = 2,
["1543"] = 2,
["1555"] = 1,
["1566"] = 4,
["1567"] = 4,
["1591"] = 1,
["1592"] = 1,
["1594"] = 2,
["1595"] = 2,
["1601"] = 1,
["1602"] = 1,
["1603"] = 2,
["1604"] = 2,
["1659"] = 4,
["1660"] = 4,
["1661"] = 4,
["1662"] = 4,
["1663"] = 4,
["1664"] = 4,
["1684"] = 4,
["1685"] = 4,
["1686"] = 4,
["1687"] = 4,
["1688"] = 4,
["1689"] = 4,
["1705"] = 4,
["1706"] = 4,
["1707"] = 4,
["1790"] = 2,
["1791"] = 2,
["1792"] = 2,
["1793"] = 2,
["1794"] = 2,
["1795"] = 2,
["1796"] = 2,
["1797"] = 2,
["1798"] = 2,
["1862"] = 1,
["1863"] = 4,
["1864"] = 4,
["1895"] = 4,
["1896"] = 4,
["1897"] = 4,
["1898"] = 4,
["1899"] = 4,
["1900"] = 4,
["1901"] = 4,
["1902"] = 4,
["1903"] = 4,

0 comments on commit e6aa220

Please sign in to comment.