git: 7f7a8549a45b - main - security/rubygem-cancancan: Add rubygem-cancancan 3.5.0

From: Po-Chuan Hsieh <sunpoet_at_FreeBSD.org>
Date: Thu, 16 May 2024 06:29:40 UTC
The branch main has been updated by sunpoet:

URL: https://cgit.FreeBSD.org/ports/commit/?id=7f7a8549a45bde7be3734eaf9d38976164c20566

commit 7f7a8549a45bde7be3734eaf9d38976164c20566
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2024-05-16 06:13:49 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2024-05-16 06:21:52 +0000

    security/rubygem-cancancan: Add rubygem-cancancan 3.5.0
    
    CanCanCan is an authorization library for Ruby and Ruby on Rails which restricts
    what resources a given user is allowed to access.
    
    All permissions can be defined in one or multiple ability files and not
    duplicated across controllers, views, and database queries, keeping your
    permissions logic in one place for easy maintenance and testing.
    
    It consists of two main parts:
    - Authorizations library that allows you to define the rules to access different
      objects, and provides helpers to check for those permissions.
    - Rails helpers to simplify the code in Rails Controllers by performing the
      loading and checking of permissions of models automatically and reduce
      duplicated code.
---
 security/Makefile                    |  1 +
 security/rubygem-cancancan/Makefile  | 16 ++++++++++++++++
 security/rubygem-cancancan/distinfo  |  3 +++
 security/rubygem-cancancan/pkg-descr | 13 +++++++++++++
 4 files changed, 33 insertions(+)

diff --git a/security/Makefile b/security/Makefile
index 09bc64eeb561..c029efaad458 100644
--- a/security/Makefile
+++ b/security/Makefile
@@ -1108,6 +1108,7 @@
     SUBDIR += rubygem-bcrypt
     SUBDIR += rubygem-bcrypt-ruby
     SUBDIR += rubygem-bcrypt_pbkdf
+    SUBDIR += rubygem-cancancan
     SUBDIR += rubygem-cose
     SUBDIR += rubygem-cvss-suite
     SUBDIR += rubygem-declarative_policy
diff --git a/security/rubygem-cancancan/Makefile b/security/rubygem-cancancan/Makefile
new file mode 100644
index 000000000000..b4e77e7c4284
--- /dev/null
+++ b/security/rubygem-cancancan/Makefile
@@ -0,0 +1,16 @@
+PORTNAME=	cancancan
+PORTVERSION=	3.5.0
+CATEGORIES=	security rubygems
+MASTER_SITES=	RG
+
+MAINTAINER=	sunpoet@FreeBSD.org
+COMMENT=	Simple authorization solution for Rails with all permissions stored in a single location
+WWW=		https://github.com/CanCanCommunity/cancancan
+
+LICENSE=	MIT
+
+USES=		gem
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/security/rubygem-cancancan/distinfo b/security/rubygem-cancancan/distinfo
new file mode 100644
index 000000000000..c77ca721ba54
--- /dev/null
+++ b/security/rubygem-cancancan/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1714227824
+SHA256 (rubygem/cancancan-3.5.0.gem) = 85fe7777f3c65fb5e55612bd1cacbd52963a981bbc697eefd5ff57edb64bb6c0
+SIZE (rubygem/cancancan-3.5.0.gem) = 29696
diff --git a/security/rubygem-cancancan/pkg-descr b/security/rubygem-cancancan/pkg-descr
new file mode 100644
index 000000000000..6ad7a47d2c3a
--- /dev/null
+++ b/security/rubygem-cancancan/pkg-descr
@@ -0,0 +1,13 @@
+CanCanCan is an authorization library for Ruby and Ruby on Rails which restricts
+what resources a given user is allowed to access.
+
+All permissions can be defined in one or multiple ability files and not
+duplicated across controllers, views, and database queries, keeping your
+permissions logic in one place for easy maintenance and testing.
+
+It consists of two main parts:
+- Authorizations library that allows you to define the rules to access different
+  objects, and provides helpers to check for those permissions.
+- Rails helpers to simplify the code in Rails Controllers by performing the
+  loading and checking of permissions of models automatically and reduce
+  duplicated code.