# Introducing Berm

**URL:** <https://forum.crystal-lang.org/t/introducing-berm/2206>\
**Category:** News\
**Created:** [June 5, 2020, 8:24pm UTC](https://forum.crystal-lang.org/t/introducing-berm/2206 "2020-06-05T20:24:11Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![giuse](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.crystal-lang.org/giuse/32/600_2.png) [@giuse](https://forum.crystal-lang.org/u/giuse)\
**Post date:** [June 5, 2020, 8:24pm UTC](https://forum.crystal-lang.org/t/introducing-berm/2206/1 "2020-06-05T20:24:11Z")

</div>

Hi! I made this little library to experiment with macros, it’s a little library that lets you manage permissions.

> **[giuseongit/Berm](https://github.com/giuseongit/Berm)**
>
> A simple library that helps to manage permissions. - giuseongit/Berm

Any comment or review is really appreciated!

---

<div class="post-metadata">

**Author:** ![Blacksmoke16](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.crystal-lang.org/blacksmoke16/32/1241_2.png) [@Blacksmoke16](https://forum.crystal-lang.org/u/Blacksmoke16)\
**Post date:** [June 5, 2020, 8:50pm UTC](https://forum.crystal-lang.org/t/introducing-berm/2206/2 "2020-06-05T20:50:06Z")

</div>

Whats the benefit over just using a [Flags Enum](https://crystal-lang.org/api/master/Enum.html#flags-enum)?

[https://play.crystal-lang.org/#/r/97sk](https://play.crystal-lang.org/#/r/97sk)

```
@[Flags]
enum MyFlags
  Read
  Write
  
  ReadWrite = Read | Write
end
 
pp MyFlags::Read.read? # => true
pp MyFlags::Write.read? # => false
pp MyFlags::ReadWrite.read? # => true
pp MyFlags::ReadWrite.write? # => true
pp MyFlags::None.write? # => false
pp MyFlags::All.write? # => true

```

(cross post from [Reddit](https://www.reddit.com/r/crystal_programming/comments/gxcbfn/introducing_berm/ft0fgd1/))

---

<div class="post-metadata">

**Author:** ![giuse](https://yyz2.discourse-cdn.com/flex036/user_avatar/forum.crystal-lang.org/giuse/32/600_2.png) [@giuse](https://forum.crystal-lang.org/u/giuse)\
**Post date:** [June 8, 2020, 7:51am UTC](https://forum.crystal-lang.org/t/introducing-berm/2206/3 "2020-06-08T07:51:48Z")

</div>

Actually none, I suppose. I’m new to Crystal, didn’t know about all the capabilities of flag enums and I wanted to experiment with macros. I build this object in python for work purposes and decided to reproduce in crystal, playing with ci and shards to learn something new ans I wanted to provide a really simple way to make an object for manage permissions. At lest this could be the base code where more useful features can be built upon
