flipt_client 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3fba410b0fcad63979b3cb5f1e0128afccf64054e3b4ad0712c3040c946beaff
4
- data.tar.gz: 56b652a202967aae88db7c4915a259f4490f5f9be043e008215728acf018dcd4
3
+ metadata.gz: adb43f640ea6aec50fc212f5641bbd77b38a55f4bc607304be1b7cf10cbf9150
4
+ data.tar.gz: 03352f854828293e78eef89845c4ca69384b4551f3ac5966edb4f417dccd218c
5
5
  SHA512:
6
- metadata.gz: f64f29f65b557a948ee83e20dea471b21c7c7c55561145c223c94e7dd35090dc61265ae0017ce8975bf271552fe8ed09a1140b5f549edc483d9e73e8be1a9514
7
- data.tar.gz: ed2f3b489f6931b4bcd057d4f60a75c04d26d6b1b618bd69c8583631f74b1405f47f86859ebab42d898b766c62b1b9b535c7e8eb68d59e93d5cc1c6114aada14
6
+ metadata.gz: 25fb6f83ba21997d21510714fd34acd1eef609cbb024129b415639d8e2063ab229a71e97965c0b6aecf8789318cec483e29c11a712dcc18e3d4c7d0d26a17ec9
7
+ data.tar.gz: b837844841904b2dd17fc87e08d899c0b0054a43f75eb6287e53800436d6beb49a472e065ba1780f4dde7a57bce2de2ce03102ce5f7cf07e52116c880f87a64c
data/README.md CHANGED
@@ -1,51 +1,15 @@
1
+ <!-- Last updated: Wed Dec 27 18:39:24 UTC 2023 -->
1
2
  # Flipt Client Ruby
2
3
 
3
- The `flipt-client-ruby` directory contains the Ruby source code for the Flipt client-side evaluation client.
4
+ [![Gem Version](https://badge.fury.io/rb/flipt_client.svg)](https://badge.fury.io/rb/flipt_client)
4
5
 
5
- ## Installation
6
-
7
- Currently, to use this client, you'll need to build the dynamic library and the gem locally and install it. This is a temporary solution until we can figure out a better way to package and distribute the libraries.
8
-
9
- The dynamic library will contain the functionality necessary for the client to make calls to the Flipt engine via FFI. See [flipt-engine](../flipt-engine) for more information on the Flipt engine and FFI.
10
-
11
- ### Prerequisites
12
-
13
- - [Rust](https://www.rust-lang.org/tools/install)
14
- - [Ruby](https://www.ruby-lang.org/en/documentation/installation/)
15
- - [Make](https://www.gnu.org/software/make/)
16
-
17
- ### Automated Build
18
-
19
- 1. Build and copy the dynamic library to the `flipt-client-ruby/lib/ext` directory for your platform. This will also build and install the `flipt_client` gem on your local machine. You can do this by running the following command from the root of the repository:
20
-
21
- ```bash
22
- make ruby
23
- ```
24
-
25
- ### Manual Build
26
-
27
- 1. Build the Rust dynamic library
6
+ The `flipt-client-ruby` directory contains the Ruby source code for the Flipt [client-side evaluation](https://www.flipt.io/docs/integration/client) client.
28
7
 
29
- ```bash
30
- cargo build --release
31
- ```
32
-
33
- This should generate a `target/` directory in the root of this repository, which contains the dynamically linked library built for your platform.
34
-
35
- 2. You'll need to copy the dynamic library to the `flipt-client-ruby/lib/ext/$OS_$ARCH/` directory. This is a temporary solution until we can figure out a better way to package the libraries with the gem.
36
-
37
- The `path/to/lib` will be the path to the dynamic library which will have the following paths depending on your platform.
38
-
39
- - **Linux**: `{REPO_ROOT}/target/release/libfliptengine.so`
40
- - **Windows**: `{REPO_ROOT}/target/release/libfliptengine.dll`
41
- - **MacOS**: `{REPO_ROOT}/target/release/libfliptengine.dylib`
42
-
43
- 3. You can then build the gem and install it locally. You can do this by running the following command from the `flipt-client-ruby` directory:
8
+ ## Installation
44
9
 
45
- ```bash
46
- rake build
47
- gem install pkg/flipt_client-{version}.gem
48
- ```
10
+ ```bash
11
+ gem install flipt_client
12
+ ```
49
13
 
50
14
  ## Usage
51
15
 
Binary file
Binary file
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Flipt
4
- VERSION = '0.0.1'
4
+ VERSION = '0.0.2'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: flipt_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Flipt Devs
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2023-12-25 00:00:00.000000000 Z
11
+ date: 2023-12-27 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: Flipt Client Evaluation SDK
14
14
  email:
@@ -22,7 +22,6 @@ files:
22
22
  - lib/ext/darwin_arm64/libfliptengine.d
23
23
  - lib/ext/darwin_arm64/libfliptengine.dylib
24
24
  - lib/ext/darwin_arm64/libfliptengine.rlib
25
- - lib/ext/flipt_engine.h
26
25
  - lib/ext/linux_arm64/libfliptengine.d
27
26
  - lib/ext/linux_arm64/libfliptengine.rlib
28
27
  - lib/ext/linux_arm64/libfliptengine.so
@@ -1,32 +0,0 @@
1
- #include <stdarg.h>
2
- #include <stdbool.h>
3
- #include <stdint.h>
4
- #include <stdlib.h>
5
-
6
- /**
7
- * # Safety
8
- *
9
- * This function will initialize an Engine and return a pointer back to the caller.
10
- */
11
- void *initialize_engine(const char *const *namespaces, const char *opts);
12
-
13
- /**
14
- * # Safety
15
- *
16
- * This function will take in a pointer to the engine and return a variant evaluation response.
17
- */
18
- const char *evaluate_variant(void *engine_ptr, const char *evaluation_request);
19
-
20
- /**
21
- * # Safety
22
- *
23
- * This function will take in a pointer to the engine and return a boolean evaluation response.
24
- */
25
- const char *evaluate_boolean(void *engine_ptr, const char *evaluation_request);
26
-
27
- /**
28
- * # Safety
29
- *
30
- * This function will free the memory occupied by the engine.
31
- */
32
- void destroy_engine(void *engine_ptr);