sept 1.2.1 → 1.2.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 +4 -4
- data/bin/sept +33 -0
- metadata +4 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: c7344a5f0ac93e272ca70fcce0f415daebcdd241
|
|
4
|
+
data.tar.gz: efbc7e7b29f83528821e3186ce389d6229703ffe
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 1049533138a3de4cd65dd9a20e1b37f76efe74d64d1d36e983af7f3cc52d7792f89e0f0a85573999714c0327269e37b1280345df35775db13254567a3824606b
|
|
7
|
+
data.tar.gz: 5acdb9e9ca9a43d2b7f3c164d3a166490f750de7b92edf9d545ff024b307798908bbcdd2df5a24a51314aa94171c87cf72897a65ef8821d053e2faf933cfc702
|
data/bin/sept
ADDED
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
#!/usr/bin/env ruby
|
|
2
|
+
|
|
3
|
+
%w(sept colorize).each { |f| require f }
|
|
4
|
+
|
|
5
|
+
if ARGV.length == 0
|
|
6
|
+
puts "ERROR No arguments passed!".red
|
|
7
|
+
else
|
|
8
|
+
case ARGV[0]
|
|
9
|
+
when "-h" # help
|
|
10
|
+
puts 'S-Expression Powered Template HyperText Markup Language',
|
|
11
|
+
'To get version, run `sept -v`',
|
|
12
|
+
'To pass some data, run `sept -d <data> files...`',
|
|
13
|
+
'<data> is a ruby hash ({:key => "value",})',
|
|
14
|
+
'To pass some data via file, run `sept -f <datafile> files...`',
|
|
15
|
+
'<datafile> is a file with ruby hash',
|
|
16
|
+
'Be careful! Any ruby code can be passed along with hash,',
|
|
17
|
+
'validation coming soon'
|
|
18
|
+
when "-v" # version
|
|
19
|
+
# TODO: fetch version from sept.gemspec automatically
|
|
20
|
+
puts "SEPT HTML version 1.2.2"
|
|
21
|
+
when "-d" # data
|
|
22
|
+
# TODO: `eval` is bad, add validation or something like that
|
|
23
|
+
# maybe json?
|
|
24
|
+
puts "Passed data as argument"
|
|
25
|
+
sept = Sept.new(eval(ARGV[1]), ARGV[2..-1])
|
|
26
|
+
when '-f' # file
|
|
27
|
+
puts "Passed data as file"
|
|
28
|
+
sept = Sept.new(eval(File.read ARGV[1]), ARGV[2..-1])
|
|
29
|
+
else
|
|
30
|
+
puts "No passed data"
|
|
31
|
+
sept = Sept.new({}, ARGV)
|
|
32
|
+
end
|
|
33
|
+
end
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sept
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.2.
|
|
4
|
+
version: 1.2.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Timur Ismagilov
|
|
@@ -13,10 +13,12 @@ dependencies: []
|
|
|
13
13
|
description: Write your HTML pages like Lisp code. Support of included files, parameters.
|
|
14
14
|
CLI utility provided.
|
|
15
15
|
email: bouncepaw2@ya.ru
|
|
16
|
-
executables:
|
|
16
|
+
executables:
|
|
17
|
+
- sept
|
|
17
18
|
extensions: []
|
|
18
19
|
extra_rdoc_files: []
|
|
19
20
|
files:
|
|
21
|
+
- bin/sept
|
|
20
22
|
- lib/sept.rb
|
|
21
23
|
homepage: https://github.com/bouncepaw/sept
|
|
22
24
|
licenses:
|