From c8d18c9c1fa16becb3b6829ee0750a9b43f4ad27 Mon Sep 17 00:00:00 2001 From: USAMI Kenta Date: Sun, 16 Apr 2023 21:53:11 +0900 Subject: [PATCH 1/7] Update Lisp headers and doc comments --- ob-phpstan.el | 35 +++++++++++++++++------------------ 1 file changed, 17 insertions(+), 18 deletions(-) diff --git a/ob-phpstan.el b/ob-phpstan.el index d091b57..668bc71 100644 --- a/ob-phpstan.el +++ b/ob-phpstan.el @@ -1,38 +1,37 @@ -;;; ob-phpstan.el --- run phpstan with org-babel -*- lexical-binding: t -*- +;;; ob-phpstan.el --- Babel Functions for PHPStan -*- lexical-binding: t; -*- -;; Author: Takeo Obara -;; Maintainer: Takeo Obara -;; Version: v1.0.0 -;; Package-Requires: ((emacs "29.0")) -;; Homepage: https://github.com/takeokunn/ob-phpstan -;; Keywords: phpstan, org, babel +;; Copyright (C) 2023 Takeo Obara -;; This file is not part of GNU Emacs +;; Author: Takeo Obara +;; Version: 0.0.1 +;; Package-Requires: ((emacs "28") (org "9")) +;; Homepage: https://github.com/emacs-php/ob-phpstan +;; Keywords: tools, org, literate programming, reproducible research, php +;; License: GPL-3.0-or-later -;; This file is free software; you can redistribute it and/or modify +;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 3, or (at your option) -;; any later version. +;; the Free Software Foundation, either version 3 of the License, or +;; (at your option) any later version. ;; This program is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. -;; For a full copy of the GNU General Public License -;; see . - +;; You should have received a copy of the GNU General Public License +;; along with this program. If not, see . ;;; Commentary: -;; run phpstan with org-babel +;; Static analyze a block of PHP code with org-babel using PHPStan. ;;; Code: (require 'org) (require 'ob) (defgroup ob-phpstan nil - "org-mode blocks for phpstan" + "org-mode blocks for PHPStan." :group 'org) (defcustom org-babel-phpstan-command "phpstan" @@ -47,7 +46,8 @@ ;;;###autoload (defun org-babel-execute:phpstan (body params) - "Org mode fish evaluate function" + "Static analyze a block of PHP code with org-babel using PHPStan. +This function is called by `org-babel-execute-src-block'." (let ((tmp-file (org-babel-temp-file "phpstan-" ".php")) (body (concat " Date: Fri, 15 Sep 2023 15:00:10 -0700 Subject: [PATCH 2/7] test: Build with Eask --- .github/dependabot.yml | 6 +++++ .github/workflows/test.yml | 54 ++++++++++++++++++++++++++++++++++++++ .gitignore | 2 ++ Eask | 18 +++++++++++++ 4 files changed, 80 insertions(+) create mode 100644 .github/dependabot.yml create mode 100644 .github/workflows/test.yml create mode 100644 Eask diff --git a/.github/dependabot.yml b/.github/dependabot.yml new file mode 100644 index 0000000..253bcb7 --- /dev/null +++ b/.github/dependabot.yml @@ -0,0 +1,6 @@ +version: 2 +updates: + - package-ecosystem: github-actions + directory: / + schedule: + interval: daily diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..fff42f0 --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,54 @@ +name: CI + +on: + push: + branches: + - master + pull_request: + workflow_dispatch: + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: true + +jobs: + test: + runs-on: ${{ matrix.os }} + continue-on-error: ${{ matrix.experimental }} + strategy: + fail-fast: false + matrix: + os: [ubuntu-latest, macos-latest, windows-latest] + emacs-version: + - 26.3 + - 27.2 + - 28.2 + - 29.1 + experimental: [false] + include: + - os: ubuntu-latest + emacs-version: snapshot + experimental: true + - os: macos-latest + emacs-version: snapshot + experimental: true + - os: windows-latest + emacs-version: snapshot + experimental: true + + steps: + - uses: actions/checkout@v4 + + - uses: jcs090218/setup-emacs@master + with: + version: ${{ matrix.emacs-version }} + + - uses: emacs-eask/setup-eask@master + with: + version: 'snapshot' + + - name: Run tests + run: | + eask package + eask install + eask compile diff --git a/.gitignore b/.gitignore index c531d98..0eee400 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,3 @@ *.elc +/.eask/ +/dist diff --git a/Eask b/Eask new file mode 100644 index 0000000..66026ca --- /dev/null +++ b/Eask @@ -0,0 +1,18 @@ +(package "ob-phpstan" + "0.0.1" + "Babel Functions for PHPStan") + +(website-url "https://github.com/emacs-php/ob-phpstan") +(keywords "tools" "org" "literate programming" "reproducible research" "php") + +(package-file "ob-phpstan.el") + +(script "test" "echo \"Error: no test specified\" && exit 1") + +(source 'gnu) +(source 'melpa) + +(depends-on "emacs" "28") +(depends-on "org" "9") + +(setq network-security-level 'low) ; see https://github.com/jcs090218/setup-emacs-windows/issues/156#issuecomment-932956432 From b86ce067f9392753433d4f9912ed5faf03a8b2db Mon Sep 17 00:00:00 2001 From: JenChieh Date: Fri, 15 Sep 2023 15:03:33 -0700 Subject: [PATCH 3/7] Correct test versions --- .github/workflows/test.yml | 2 -- 1 file changed, 2 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index fff42f0..1685b4c 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -20,8 +20,6 @@ jobs: matrix: os: [ubuntu-latest, macos-latest, windows-latest] emacs-version: - - 26.3 - - 27.2 - 28.2 - 29.1 experimental: [false] From c77355e70703affffb166b7100b9e9f3efb21c6e Mon Sep 17 00:00:00 2001 From: Jen-Chieh Shen Date: Wed, 27 Mar 2024 00:19:26 -0700 Subject: [PATCH 4/7] ci: Bump Emacs 29.x to 3 --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 1685b4c..ff4a8d2 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -21,7 +21,7 @@ jobs: os: [ubuntu-latest, macos-latest, windows-latest] emacs-version: - 28.2 - - 29.1 + - 29.3 experimental: [false] include: - os: ubuntu-latest From 8846475a2fb1b7e72d7cd49ec8b76c1292fb0e96 Mon Sep 17 00:00:00 2001 From: Jen-Chieh Shen Date: Tue, 22 Apr 2025 17:21:02 -0700 Subject: [PATCH 5/7] fix: Warning missing lexical-binding cookie --- Eask | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Eask b/Eask index 66026ca..af66a21 100644 --- a/Eask +++ b/Eask @@ -1,3 +1,5 @@ +;; -*- mode: eask; lexical-binding: t -*- + (package "ob-phpstan" "0.0.1" "Babel Functions for PHPStan") From 12ed94eb22d2c48d80a5d48196aff41d309ad288 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Aug 2025 20:40:21 +0000 Subject: [PATCH 6/7] Bump actions/checkout from 4 to 5 Bumps [actions/checkout](https://github.com/actions/checkout) from 4 to 5. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v4...v5) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '5' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index ff4a8d2..2ebda69 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -35,7 +35,7 @@ jobs: experimental: true steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v5 - uses: jcs090218/setup-emacs@master with: From 6673da2a7054dc2635592c05c0af8f08d894b9d9 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Fri, 21 Nov 2025 15:09:39 +0000 Subject: [PATCH 7/7] Bump actions/checkout from 5 to 6 Bumps [actions/checkout](https://github.com/actions/checkout) from 5 to 6. - [Release notes](https://github.com/actions/checkout/releases) - [Changelog](https://github.com/actions/checkout/blob/main/CHANGELOG.md) - [Commits](https://github.com/actions/checkout/compare/v5...v6) --- updated-dependencies: - dependency-name: actions/checkout dependency-version: '6' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- .github/workflows/test.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 2ebda69..0d2eef4 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -35,7 +35,7 @@ jobs: experimental: true steps: - - uses: actions/checkout@v5 + - uses: actions/checkout@v6 - uses: jcs090218/setup-emacs@master with: