Skip to content

Commit dd4a06c

Browse files
committed
updated README
1 parent be02a1d commit dd4a06c

File tree

2 files changed

+19
-4
lines changed

2 files changed

+19
-4
lines changed

.gitignore

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,12 @@
1+
# Ignore build output
2+
/dist/
3+
4+
# Ignore SQLite amalgamation sources
5+
/src/sqlite3.c
6+
/src/sqlite3.h
7+
/src/sqlite3ext.h
8+
/src/shell.c
9+
110
*.log
211

312
# Prerequisites

README.md

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -74,10 +74,10 @@ make compile-macos # For macOS
7474
After compilation, you can load the extensions in your SQLite shell using:
7575

7676
```sql
77-
.load '/path/to/dist/json_equal'
78-
.load '/path/to/dist/regexp'
79-
.load '/path/to/dist/split_part'
80-
.load '/path/to/dist/aws_policy_equal'
77+
.load 'dist/json_equal'
78+
.load 'dist/regexp'
79+
.load 'dist/split_part'
80+
.load 'dist/aws_policy_equal'
8181
```
8282

8383
Alternatively, you can download the extensions from [__sqlpkg__](https://sqlpkg.org/?q=stackql%2Fjson_equal).
@@ -99,6 +99,12 @@ SELECT aws_policy_equal(
9999
'{"Version":"2012-10-17","Statement":[{"Effect":"Allow","Action":["s3:PutObject","s3:GetObject"],"Resource":"*"}]}'
100100
); -- Returns 1 (true)
101101

102+
-- Compare AWS policies which are different
103+
SELECT aws_policy_equal(
104+
'{"Version":"2012-10-17","Statement":[{"Effect":"Allow","Action":["s3:GetObject","s3:PutObject"],"Resource":"*"}]}',
105+
'{"Version":"2012-10-17","Statement":[{"Effect":"Deny","Action":["s3:PutObject","s3:GetObject"],"Resource":"*"}]}'
106+
); -- Returns 0 (false)
107+
102108
-- Compare trust policies with different Principal formats
103109
SELECT aws_policy_equal(
104110
'{"Version":"2012-10-17","Statement":[{"Effect":"Allow","Principal":{"AWS":"arn:aws:iam::123456789012:role/role1"},"Action":"sts:AssumeRole"}]}',

0 commit comments

Comments
 (0)