Skip to content

CI

CI #664

Workflow file for this run

# 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:
- cron: '1 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
env:
passwd: ${{ secrets.PASSWD }}
# 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@v3
# Runs a set of commands using the runners shell
- name: Download curl
run: |
wget https://github.com/lwthiker/curl-impersonate/releases/download/v0.5.4/curl-impersonate-v0.5.4.x86_64-linux-gnu.tar.gz
tar -zxvf curl-impersonate-v0.5.4.x86_64-linux-gnu.tar.gz
pwd
ls
chmod +x curl_edge101
- name: Download image
run: |
Date=$(date "+%Y%m%d")
./curl_edge101 https://rdpic.marisa.ml/1.png -L -o $Date.png
- name: set git env
run: |
git config --global user.email "[email protected]"
git config --global user.name "guihongwong"
git config --global user.password $passwd
- name: spread image
run: |
cp *.png Delopy.png
ls
pwd
git clone https://guihongwong:"$passwd"@github.com/GDWGH/rdthimg-front.git
mkdir temp
cd rdthimg-front
cp index.html /home/runner/work/rdthimg-backend/rdthimg-backend/temp/
cp -r .github /home/runner/work/rdthimg-backend/rdthimg-backend/temp/
git rm * -r
git commit -m "Ze☆"
cp /home/runner/work/rdthimg-backend/rdthimg-backend/temp/index.html /home/runner/work/rdthimg-backend/rdthimg-backend/rdthimg-front/
cp /home/runner/work/rdthimg-backend/rdthimg-backend/*.png /home/runner/work/rdthimg-backend/rdthimg-backend/rdthimg-front/
git add .
git commit -m "Ze☆"
git branch -M main
git push -u origin main