dot_grid 0.0.9 → 0.0.10

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: 8a8a13e059d013b2349a61cdc460e3d6630a4d3b
4
- data.tar.gz: bbb99be909ece712429a32064bc1cf275acb0615
3
+ metadata.gz: 2d20dc3dcfaf751ae3bac1db9370a7b096441068
4
+ data.tar.gz: 61c84e76ed26fb9fff8a327e9c0fd9260bed6713
5
5
  SHA512:
6
- metadata.gz: 8fc5cd005c24da97c7314d2c612c273d46b3fe68271528ee731e56cedeb2680e4fc7af783c050449f362dd71021f2b43f8adfd8800c237b38226bad86366240a
7
- data.tar.gz: ef0e80294f9663c7a988f3800b7ab1f5ba87fcfd0a4bf93f953468a23e7843ae8fa7ad1ae6ae27b7f9a4d34ca3ceac2bd064e9ee780e49da0bd67cb70e7cf25d
6
+ metadata.gz: c04ce6ff5138b6cfc8857798c1ba2cb8462c55852c2bef6a86da3fa4b78769940a6c93dc541e76d036e7ae248ec9d8b8cc5fc20c51bdcef9a80078df38093d1b
7
+ data.tar.gz: b600b4427e8285b10e9104a960d79a45767474769273b3414f127aecbf4cd96032f240b584a36fabcb82f16ee8bda0dd335b8c41877891983618a8582550e56e
data/README.md CHANGED
@@ -14,7 +14,7 @@ A simple ruby file for generating dot grid graph paper.
14
14
  ## CLI
15
15
 
16
16
  ### A basic dot grid page can be generated like this ...
17
- dot_grid -f dot_grid.pdf --page-types dot-grid --spacing 5 --grid-color CFBAEC --dot-weight 0.5 -m 0.0
17
+ dot_grid -f dot_grid.pdf --page-types dot_grid --spacing 5 --grid-color CFBAEC --dot-weight 0.5 -m 0.0
18
18
 
19
19
  ### A basic planning page can be generated like this ...
20
20
  dot_grid -f planner_w5_c2dfff.pdf --page-types planner --grid-color CFBAEC --dot-weight 0.5 -m 0.0 --planner-color-1 dddddd --planner-color-2 C2DFFF
@@ -23,7 +23,7 @@ A simple ruby file for generating dot grid graph paper.
23
23
  dot_grid -f grid_c2dfff.pdf --page-types grid --spacing 5 --grid-color CFBAEC --margin 0.0
24
24
 
25
25
  ### A horizontal rule page
26
- dot_grid -f horizontal_rule_c2dfff.pdf --page-types horizontal-rule --spacing 5 --grid-color CFBAEC --margin 0.0
26
+ dot_grid -f horizontal_rule_c2dfff.pdf --page-types horizontal_rule --spacing 5 --grid-color CFBAEC --margin 0.0
27
27
 
28
28
  ### A checkerboard page
29
29
  dot_grid -f checkerboard_c2dfff.pdf --page-types checkerboard --spacing 5 --grid-color CFBAEC --margin 0.0
data/lib/dot_grid/cli.rb CHANGED
@@ -8,7 +8,7 @@ module DotGrid
8
8
  version "dot_grid #{DotGrid::VERSION}"
9
9
  opt :file_name, "File Name", :type => :string, :default => "dotgrid.pdf"
10
10
  opt :orientation, "Orientation of pages (portrait/landscape)", type: :string, default: "portrait"
11
- opt :page_types, "Types of pages desired: Types of pages desired: DotGrid, Planner, Grid, HorizontalRule, Checkerboard", type: :string, default: "Planner"
11
+ opt :page_types, "Types of pages desired: Types of pages desired: DotGrid, Planner, Grid, HorizontalRule, Checkerboard", type: :string, default: "planner"
12
12
  opt :dot_weight, "Dot Weight", :type => :float, :default => 1.5
13
13
  opt :margin, "Border", :type => :float, :default => 0.0
14
14
  opt :page_size, "Page Size (LEGAL, LETTER)", :type => :string, :default => "LETTER"
@@ -16,7 +16,7 @@ module DotGrid
16
16
  @page_size = params[:page_size] ? parse_page_size(params[:page_size]) : "LETTER"
17
17
  @orientation = params[:orientation] ? params[:orientation].downcase.to_sym : :portrait
18
18
  @margin = params[:margin] || 0.0
19
- @page_types = params[:page_types] ? params[:page_types].split(",") : ["planner"]
19
+ @page_types = params[:page_types] ? params[:page_types].downcase.split(",").map { |w| w.strip } : ["planner"]
20
20
 
21
21
  @pdf = Prawn::Document.new(margin: margin, page_size: page_size, skip_page_creation: true, page_layout: orientation)
22
22
  @pages = create_pages(params.merge({pdf: pdf}))
@@ -29,7 +29,7 @@ module DotGrid
29
29
 
30
30
  def create_pages(params)
31
31
  page_types.map do |p|
32
- DotGrid::Page::Factory.build(p.strip, params.clone)
32
+ DotGrid::Page::Factory.build(p, params.clone)
33
33
  end
34
34
  end
35
35
 
@@ -1,3 +1,3 @@
1
1
  module DotGrid
2
- VERSION = "0.0.9"
2
+ VERSION = "0.0.10"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: dot_grid
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.9
4
+ version: 0.0.10
5
5
  platform: ruby
6
6
  authors:
7
7
  - Scott LaBounty
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-08-10 00:00:00.000000000 Z
11
+ date: 2014-08-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rspec