cass_schema 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ed62cce9c48b24a103e72a5ac83df927bee4986a
4
- data.tar.gz: 855847953f7f9c54933ab532b7524d81b80aac40
3
+ metadata.gz: ecc2963be5c305ab9bf221b4c0e83e8be5de46eb
4
+ data.tar.gz: 14a69808bd70ed8894de921dc4e4f1288e1e955a
5
5
  SHA512:
6
- metadata.gz: 90961f405aca7ae569903d92368e5f0fd1a36eb123852644734974956d8ea64d2a75e5b73e9064e4a5797e1ae71f6eda892fe3cd2084bd7745e660cf8f22bf04
7
- data.tar.gz: 5cad1a2a5eff5824ce8817ca336ccc79e8fdcfc45121e9f99f4f30d6d9e92b0f27b7df20eef12ed850ea349307fabfa18da8190ac96a5c0ed1d5bc0d1eab4622
6
+ metadata.gz: a98ae845a77a4f3f9662c5896b7bb2a1902d3a9aa6d4fdde53074f553926ceba18aa5a5186567c5c49e7882f18a3b162686a042c37cd58acf94d02dfb469d647
7
+ data.tar.gz: 34f8761b17259b8c5dae3f9463b7db27a6c4a6442ecea43c1d3c3c92ae95b148cf2cd96df6338164709ca718cc7b4af0616a7899b373c40d89cfec61fcdff0ad
@@ -7,13 +7,16 @@ module CassSchema
7
7
 
8
8
  # Parse the individual CQL statements as a list from the file. To do so:
9
9
  # - assume statements are separated by two new lines
10
- # - strip comments and empty lines from each statement
10
+ # - strip comments (#,--,//) and empty lines from each statement
11
11
  # - remove statements that are empty
12
+ # - Note that /* multiline comments */ are not supported
12
13
  statements = file.split(/\n{2,}/).map do |statement|
13
14
  statement
14
15
  .split(/\n/)
15
16
  .select { |l| l !~ /^\s*#/ }
16
17
  .select { |l| l !~ /^\s*$/ }
18
+ .select { |l| l !~ /^\s*--.*$/ }
19
+ .select { |l| l !~ /^\s*\/\/.*$/ }
17
20
  .join("\n")
18
21
  end
19
22
 
@@ -1,3 +1,3 @@
1
1
  module CassSchema
2
- VERSION = "0.3.1"
2
+ VERSION = "0.3.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: cass_schema
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Arron Norwell
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-05-05 00:00:00.000000000 Z
11
+ date: 2016-06-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler