unofficial mirror of guix-patches@gnu.org 
 help / color / mirror / code / Atom feed
* [bug#34751] [PATCH 0/2] Add editorconfig-vim
@ 2019-03-04 19:13 Efraim Flashner
  2019-03-04 19:15 ` [bug#34751] [PATCH 1/2] gnu: Add editorconfig-core-c Efraim Flashner
  2019-03-17 18:40 ` bug#34751: [PATCH 0/2] " Efraim Flashner
  0 siblings, 2 replies; 4+ messages in thread
From: Efraim Flashner @ 2019-03-04 19:13 UTC (permalink / raw)
  To: 34751

This is for the editorconfig plugin. There is also one for emacs, but I
haven't packaged it.

Efraim Flashner (2):
  gnu: Add editorconfig-core-c.
  gnu: Add editorconfig-vim.

 gnu/packages/text-editors.scm | 47 ++++++++++++++++++++++++++++++
 gnu/packages/vim.scm          | 54 +++++++++++++++++++++++++++++++++++
 2 files changed, 101 insertions(+)

-- 
2.21.0

^ permalink raw reply	[flat|nested] 4+ messages in thread

* [bug#34751] [PATCH 1/2] gnu: Add editorconfig-core-c.
  2019-03-04 19:13 [bug#34751] [PATCH 0/2] Add editorconfig-vim Efraim Flashner
@ 2019-03-04 19:15 ` Efraim Flashner
  2019-03-04 19:15   ` [bug#34751] [PATCH 2/2] gnu: Add editorconfig-vim Efraim Flashner
  2019-03-17 18:40 ` bug#34751: [PATCH 0/2] " Efraim Flashner
  1 sibling, 1 reply; 4+ messages in thread
From: Efraim Flashner @ 2019-03-04 19:15 UTC (permalink / raw)
  To: 34751

* gnu/packages/text-editors.scm (editorconfig-core-c): New variable.
---
 gnu/packages/text-editors.scm | 47 +++++++++++++++++++++++++++++++++++
 1 file changed, 47 insertions(+)

diff --git a/gnu/packages/text-editors.scm b/gnu/packages/text-editors.scm
index 0c60d202a3..b1afd63b32 100644
--- a/gnu/packages/text-editors.scm
+++ b/gnu/packages/text-editors.scm
@@ -6,6 +6,7 @@
 ;;; Copyright © 2017 Nils Gillmann <ng0@n0.is>
 ;;; Copyright © 2014 Taylan Ulrich Bayırlı/Kammer <taylanbayirli@gmail.org>
 ;;; Copyright © 2017, 2018 Tobias Geerinckx-Rice <me@tobias.gr>
+;;; Copyright © 2019 Efraim Flashner <efraim@flashner.co.il>
 ;;;
 ;;; This file is part of GNU Guix.
 ;;;
@@ -28,6 +29,7 @@
   #:use-module (guix git-download)
   #:use-module (guix utils)
   #:use-module (guix build-system gnu)
+  #:use-module (guix build-system cmake)
   #:use-module (guix build-system glib-or-gtk)
   #:use-module ((guix licenses) #:prefix license:)
   #:use-module (gnu packages)
@@ -41,6 +43,7 @@
   #:use-module (gnu packages libreoffice)
   #:use-module (gnu packages lua)
   #:use-module (gnu packages ncurses)
+  #:use-module (gnu packages pcre)
   #:use-module (gnu packages pkg-config)
   #:use-module (gnu packages qt)
   #:use-module (gnu packages regex)
@@ -343,3 +346,47 @@ team.")
      "@code{ghostwriter} provides a relaxing, distraction-free writing
 environment with Markdown markup.")
     (license license:gpl3+)))           ;icons/* under CC-BY-SA3
+
+(define-public editorconfig-core-c
+  (package
+    (name "editorconfig-core-c")
+    (version "0.12.3")
+    (source
+      (origin
+        (method git-fetch)
+        (uri (git-reference
+               (url "https://github.com/editorconfig/editorconfig-core-c.git")
+               (commit (string-append "v" version))))
+        (file-name (git-file-name name version))
+        (sha256
+         (base32
+          "0jkc69r4jwn4rih6h6cqvgljjc3ff49cxj8286mi515aczr48cm1"))))
+    (build-system cmake-build-system)
+    (arguments
+     '(#:phases
+       (modify-phases %standard-phases
+         (add-after 'unpack 'insert-tests
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((tests (assoc-ref inputs "tests")))
+               (copy-recursively tests "tests"))
+             #t)))))
+    (native-inputs
+     `(("tests" ,(origin
+                   (method git-fetch)
+                   (uri (git-reference
+                          (url "https://github.com/editorconfig/editorconfig-core-test")
+                          (commit "6ea1d8ece62cac9cf72c79dce4879b046abe1fe7"))) ; matches version
+                   (file-name (git-file-name "editorconfig-core-test" version))
+                   (sha256
+                    (base32
+                     "1sf6910idnd4bgzbj8w8f9ldsbkaqa0lh6syymwy3hfqda63acj7"))))))
+    (inputs
+     `(("pcre2" ,pcre2)))
+    (home-page "https://editorconfig.org/")
+    (synopsis "EditorConfig core library written in C")
+    (description "EditorConfig makes it easy to maintain the correct coding
+style when switching between different text editors and between different
+projects.  The EditorConfig project maintains a file format and plugins for
+various text editors which allow this file format to be read and used by those
+editors.")
+    (license license:bsd-2)))
-- 
2.21.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* [bug#34751] [PATCH 2/2] gnu: Add editorconfig-vim.
  2019-03-04 19:15 ` [bug#34751] [PATCH 1/2] gnu: Add editorconfig-core-c Efraim Flashner
@ 2019-03-04 19:15   ` Efraim Flashner
  0 siblings, 0 replies; 4+ messages in thread
From: Efraim Flashner @ 2019-03-04 19:15 UTC (permalink / raw)
  To: 34751

* gnu/packages/vim.scm (editorconfig-vim): New variable.
---
 gnu/packages/vim.scm | 54 ++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 54 insertions(+)

diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm
index 5e1e9b852c..d55b89d2f0 100644
--- a/gnu/packages/vim.scm
+++ b/gnu/packages/vim.scm
@@ -55,6 +55,7 @@
   #:use-module (gnu packages serialization)
   #:use-module (gnu packages shells)
   #:use-module (gnu packages tcl)
+  #:use-module (gnu packages text-editors)
   #:use-module (gnu packages terminals)
   #:use-module (gnu packages xdisorg)
   #:use-module (gnu packages xorg))
@@ -642,6 +643,59 @@ are detected, the user is notified.")
     (home-page "https://github.com/vim-syntastic/syntastic")
     (license license:wtfpl2)))
 
+(define-public editorconfig-vim
+  (package
+    (name "editorconfig-vim")
+    (version "0.3.3")
+    (source
+      (origin
+        (method git-fetch)
+        (uri (git-reference
+               (url "https://github.com/editorconfig/editorconfig-vim.git")
+               (commit (string-append "v" version))))
+        (file-name (git-file-name name version))
+        (sha256
+         (base32
+          "0vssfl1wjq0mv0p30c3dszwrh4yy90vwxmmdgqaxf5rykik7bdfd"))
+        (modules '((guix build utils)))
+        (snippet
+         '(begin
+            (delete-file-recursively "plugin/editorconfig-core-py") #t))))
+    (build-system gnu-build-system)
+    (arguments
+     '(#:tests? #f ; tests require ruby and plugin-test repository
+       #:phases
+       (modify-phases %standard-phases
+         (delete 'configure)
+         (delete 'build)
+         (add-after 'unpack 'patch-editorconfig-path
+           (lambda* (#:key inputs #:allow-other-keys)
+             (let ((editorconfig (assoc-ref inputs "editorconfig-core")))
+               (substitute* "plugin/editorconfig.vim"
+                 (("/opt") editorconfig))
+               #t)))
+         (replace 'install
+           (lambda* (#:key outputs #:allow-other-keys)
+             (let* ((out (assoc-ref outputs "out"))
+                    (vimfiles (string-append out "/share/vim/vimfiles"))
+                    (doc (string-append vimfiles "/doc"))
+                    (plugin (string-append vimfiles "/plugin"))
+                    (autoload (string-append vimfiles "/autoload")))
+               (copy-recursively "doc" doc)
+               (copy-recursively "autoload" autoload)
+               (copy-recursively "plugin" plugin)
+               #t))))))
+    (inputs
+     `(("editorconfig-core" ,editorconfig-core-c)))
+    (home-page "https://editorconfig.org/")
+    (synopsis "EditorConfig plugin for Vim")
+    (description "EditorConfig makes it easy to maintain the correct coding
+style when switching between different text editors and between different
+projects.  The EditorConfig project maintains a file format and plugins for
+various text editors which allow this file format to be read and used by those
+editors.")
+    (license license:bsd-2)))
+
 (define-public neovim-syntastic
   (package
     (inherit vim-syntastic)
-- 
2.21.0

^ permalink raw reply related	[flat|nested] 4+ messages in thread

* bug#34751: [PATCH 0/2] Add editorconfig-vim
  2019-03-04 19:13 [bug#34751] [PATCH 0/2] Add editorconfig-vim Efraim Flashner
  2019-03-04 19:15 ` [bug#34751] [PATCH 1/2] gnu: Add editorconfig-core-c Efraim Flashner
@ 2019-03-17 18:40 ` Efraim Flashner
  1 sibling, 0 replies; 4+ messages in thread
From: Efraim Flashner @ 2019-03-17 18:40 UTC (permalink / raw)
  To: 34751-done

[-- Attachment #1: Type: text/plain, Size: 229 bytes --]

Patches pushed

-- 
Efraim Flashner   <efraim@flashner.co.il>   אפרים פלשנר
GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2019-03-17 18:45 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-04 19:13 [bug#34751] [PATCH 0/2] Add editorconfig-vim Efraim Flashner
2019-03-04 19:15 ` [bug#34751] [PATCH 1/2] gnu: Add editorconfig-core-c Efraim Flashner
2019-03-04 19:15   ` [bug#34751] [PATCH 2/2] gnu: Add editorconfig-vim Efraim Flashner
2019-03-17 18:40 ` bug#34751: [PATCH 0/2] " Efraim Flashner

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/guix.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).