git: d7397758c755 - main - databases/rubygem-attr_json: Add rubygem-attr_json 2.1.0

From: Po-Chuan Hsieh <sunpoet_at_FreeBSD.org>
Date: Mon, 31 Jul 2023 16:45:25 UTC
The branch main has been updated by sunpoet:

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

commit d7397758c755b0ce762f72514ab357f200e00af6
Author:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
AuthorDate: 2023-07-31 16:27:31 +0000
Commit:     Po-Chuan Hsieh <sunpoet@FreeBSD.org>
CommitDate: 2023-07-31 16:39:46 +0000

    databases/rubygem-attr_json: Add rubygem-attr_json 2.1.0
    
    ActiveRecord attributes stored serialized in a json column, super smooth.
    
    Typed and cast like Active Record. Supporting nested models, dirty tracking,
    some querying (with postgres jsonb contains), and working smoothy with form
    builders.
    
    Use your database as a typed object store via ActiveRecord, in the same models
    right next to ordinary ActiveRecord column-backed attributes and associations.
    Your json-serialized attr_json attributes use as much of the existing
    ActiveRecord architecture as we can.
---
 databases/Makefile                    |  1 +
 databases/rubygem-attr_json/Makefile  | 19 +++++++++++++++++++
 databases/rubygem-attr_json/distinfo  |  3 +++
 databases/rubygem-attr_json/pkg-descr | 10 ++++++++++
 4 files changed, 33 insertions(+)

diff --git a/databases/Makefile b/databases/Makefile
index b3cf3b7b7c56..9e305315ad34 100644
--- a/databases/Makefile
+++ b/databases/Makefile
@@ -906,6 +906,7 @@
     SUBDIR += rubygem-arel6
     SUBDIR += rubygem-arel7
     SUBDIR += rubygem-arel8
+    SUBDIR += rubygem-attr_json
     SUBDIR += rubygem-awesome_nested_set
     SUBDIR += rubygem-bdb1
     SUBDIR += rubygem-bigrecord
diff --git a/databases/rubygem-attr_json/Makefile b/databases/rubygem-attr_json/Makefile
new file mode 100644
index 000000000000..b4d354a3ea7d
--- /dev/null
+++ b/databases/rubygem-attr_json/Makefile
@@ -0,0 +1,19 @@
+PORTNAME=	attr_json
+PORTVERSION=	2.1.0
+CATEGORIES=	databases rubygems
+MASTER_SITES=	RG
+
+MAINTAINER=	sunpoet@FreeBSD.org
+COMMENT=	Serialized json-hash-backed ActiveRecord attributes
+WWW=		https://rubygems.org/gems/attr_json
+
+LICENSE=	MIT
+LICENSE_FILE=	${WRKSRC}/LICENSE.txt
+
+USES=		gem
+
+RUN_DEPENDS=	rubygem-activerecord70>=6.0.0<7.1:databases/rubygem-activerecord70
+
+NO_ARCH=	yes
+
+.include <bsd.port.mk>
diff --git a/databases/rubygem-attr_json/distinfo b/databases/rubygem-attr_json/distinfo
new file mode 100644
index 000000000000..db733521e916
--- /dev/null
+++ b/databases/rubygem-attr_json/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1689398767
+SHA256 (rubygem/attr_json-2.1.0.gem) = 2219109fb4d99f16ed320feb08a95f708a42ce618ea1eb0374a1339c56e16a37
+SIZE (rubygem/attr_json-2.1.0.gem) = 48128
diff --git a/databases/rubygem-attr_json/pkg-descr b/databases/rubygem-attr_json/pkg-descr
new file mode 100644
index 000000000000..e8013e957921
--- /dev/null
+++ b/databases/rubygem-attr_json/pkg-descr
@@ -0,0 +1,10 @@
+ActiveRecord attributes stored serialized in a json column, super smooth.
+
+Typed and cast like Active Record. Supporting nested models, dirty tracking,
+some querying (with postgres jsonb contains), and working smoothy with form
+builders.
+
+Use your database as a typed object store via ActiveRecord, in the same models
+right next to ordinary ActiveRecord column-backed attributes and associations.
+Your json-serialized attr_json attributes use as much of the existing
+ActiveRecord architecture as we can.