Skip to content

Commit 43a8e88

Browse files
committed
% package
1 parent 181f2b3 commit 43a8e88

24 files changed

+1245
-1754
lines changed

.gitignore

+14-1
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,15 @@
1-
basil
1+
.dub
2+
docs.json
3+
__dummy.html
4+
docs/
5+
/basil
6+
basil.so
7+
basil.dylib
8+
basil.dll
9+
basil.a
10+
basil.lib
11+
basil-test-*
12+
*.pdb
213
*.o
14+
*.obj
15+
*.lst

README.md

+4-3
Original file line numberDiff line numberDiff line change
@@ -878,14 +878,14 @@ The UML diagrams can be drawn using [PlantText](https://www.planttext.com/) or [
878878
## Command line
879879

880880
```
881-
basil [options] script_file.bs [script_file.bs|bd|bt ...]
881+
basil [options] script_file.bs [script_file.bs|bd|bt|csv ...]
882882
```
883883

884884
### File extensions
885885

886886
```
887887
.bs : schema
888-
.bd : data
888+
.bd, .csv : data
889889
.bt : template
890890
```
891891

@@ -896,6 +896,7 @@ basil [options] script_file.bs [script_file.bs|bd|bt ...]
896896
--sql : generate the SQL schema and data files
897897
--cql : generate the CQL schema and data files
898898
--json : generate the JSON data file
899+
--csv : generate the CSV data files
899900
--go : generate the Go type file
900901
--generis : generate the Generis type, query, response, request and route files
901902
--phoenix : generate the Phoenix query files
@@ -910,7 +911,7 @@ basil [options] script_file.bs [script_file.bs|bd|bt ...]
910911

911912
The `--sql` and `--cql` options are mutually exhaustive.
912913

913-
The `--json`, `--go`, `--generis`, `--crystal`, `--csharp`, `--rust` and `--javascript` options require the `--sql` or the `--cql` option.
914+
The `--json`, `--csv`, `--go`, `--generis`, `--crystal`, `--csharp`, `--rust` and `--javascript` options require the `--sql` or the `--cql` option.
914915

915916
### Examples
916917

SAMPLE/CQL/blog_data.cql

+62-62
Large diffs are not rendered by default.

SAMPLE/CQL/blog_data.json

+1-1
Large diffs are not rendered by default.

SAMPLE/SQL/PHX/MODEL/subscriber.phx

+3-3
Original file line numberDiff line numberDiff line change
@@ -44,11 +44,11 @@ function GetDatabaseSubscriberById(
4444
// ~~
4545

4646
function GetDatabaseSubscriberByEmail(
47-
string email
47+
string subscriber_email
4848
)
4949
{
50-
var statement = GetDatabaseStatement( 'select `Id`, `Name`, `Email` from `SUBSCRIBER` where Email = ? limit 1' );
51-
statement.bindParam( 1, email, PDO::PARAM_STR );
50+
var statement = GetDatabaseStatement( 'select `Id`, `Name`, `Email` from `SUBSCRIBER` where `Email` = ? limit 1' );
51+
statement.bindParam( 1, subscriber_email, PDO::PARAM_STR );
5252

5353
if ( !statement.execute() )
5454
{

SAMPLE/SQL/PHX/MODEL/user.phx

+3-3
Original file line numberDiff line numberDiff line change
@@ -33,15 +33,15 @@ function GetDatabaseUserByEmailMap(
3333
var_dump( statement.errorInfo() );
3434
}
3535

36-
var user_map = [];
36+
var user_by_email_map = [];
3737

3838
while ( var user = statement.fetchObject() )
3939
{
4040
user.Id = ( int )( user.Id );
41-
user_map[ user.Email ] = user;
41+
user_by_email_map[ user.Email ] = user;
4242
}
4343

44-
return user_map;
44+
return user_by_email_map;
4545
}
4646

4747
// ~~

SAMPLE/SQL/blog_data.json

+1-1
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)