From: nishi Date: Tue, 25 Jun 2024 01:03:20 +0000 (+0000) Subject: separate actions X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=59648afab454e2657c08e145d60f5008a1c8b7ca;p=dataworks.git separate actions git-svn-id: file:///raid/svn-main/nishi-dataworks/trunk@424 d4a5a174-5a4a-5b4b-b672-37683c10d7d5 --- diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 9983d7d..c4cbec8 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -5,45 +5,8 @@ on: schedule: - cron: "0 */6 * * *" -concurrency: - group: "pages" - cancel-in-progress: true - jobs: - deploy-pages: - - name: "Deploy pages" - - runs-on: ubuntu-latest - - environment: - name: github-pages - url: ${{ steps.deployment.outputs.page_url }} - - permissions: - contents: write - pages: write - id-token: write - - steps: - - name: Checkout - uses: actions/checkout@v4 - - name: Install packages - run: sudo apt-get install zip byacc flex doxygen graphviz - - name: Make sure it is clean - run: make clean - - name: Make for Linux 64-bit - run: make YACC=byacc -j3 - - name: Setup Pages - uses: actions/configure-pages@v4 - - name: Upload pages - uses: actions/upload-pages-artifact@v3 - with: - path: "Document/doc/html" - - name: Deploy - uses: actions/deploy-pages@v4 - - build-amiga: + build-amiga: name: "Build for Amiga" diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml new file mode 100644 index 0000000..5e00280 --- /dev/null +++ b/.github/workflows/deploy.yml @@ -0,0 +1,43 @@ +name: Deploy pages + +on: + workflow_dispatch: + push: + +concurrency: + group: "pages" + cancel-in-progress: true + +jobs: + deploy-pages: + + name: "Deploy pages" + + runs-on: ubuntu-latest + + environment: + name: github-pages + url: ${{ steps.deployment.outputs.page_url }} + + permissions: + contents: write + pages: write + id-token: write + + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Install packages + run: sudo apt-get install zip byacc flex doxygen graphviz + - name: Make sure it is clean + run: make clean + - name: Make for Linux 64-bit + run: make YACC=byacc -j3 + - name: Setup Pages + uses: actions/configure-pages@v4 + - name: Upload pages + uses: actions/upload-pages-artifact@v3 + with: + path: "Document/doc/html" + - name: Deploy + uses: actions/deploy-pages@v4 diff --git a/Server/server.c b/Server/server.c index a2501c5..12e15ce 100644 --- a/Server/server.c +++ b/Server/server.c @@ -75,6 +75,8 @@ void writeline(int sock, const char* str); char* readline_sock(int sock); void disconnect(int sock); +FILE* flog; + void protocol_init(int sock) { /* sock is ignored on hayes */ char* tmp; @@ -202,7 +204,7 @@ void protocol_loop(int sock) { if(strcmp(entries[j]->pass, buf + i + 1) == 0) { writeline(sock, "LOGIN"); login = true; - printf("User %s is in\n", user); + fprintf(flog, "User %s is in\n", user); break; } else { writeline(sock, "ERROR:INVALID_PASSWORD"); @@ -237,6 +239,7 @@ void protocol_loop(int sock) { } free(buf); } + if(user != NULL) fprintf(flog, "User %s disconnected\n", user); } void exitnow(int sig) { @@ -247,8 +250,6 @@ void exitnow(int sig) { #endif } -FILE* flog; - int rescan(void) { if(entries != NULL) { fprintf(flog, "Rescan...\n");