pdd 0.5 → 0.5.1

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.
@@ -18,5 +18,5 @@ release:
18
18
  - "gem install pdd"
19
19
  - "pdd --source=$(pwd) --verbose --file=pdd.xml -e=test/** -e=features/** -e=README.md"
20
20
  - "s3cmd --no-progress put pdd.xml --config=../s3cfg s3://pdd.teamed.io/pdd.xml"
21
- - "s3cmd --no-progress put assets/puzzles.xsd --acl-public --config=../s3cfg s3://pdd.teamed.io/xsd/${tag}.xsd"
22
- - "s3cmd --no-progress put assets/puzzles.xsl --acl-public --config=../s3cfg s3://pdd.teamed.io/xsl/${tag}.xsl"
21
+ - "s3cmd --no-progress put assets/puzzles.xsd --acl-public --config=../s3cfg s3://pdd-xsd.teamed.io/${tag}.xsd"
22
+ - "s3cmd --no-progress put assets/puzzles.xsl --acl-public --config=../s3cfg s3://pdd-xsd.teamed.io/${tag}.xsl"
File without changes
File without changes
data/lib/pdd.rb CHANGED
@@ -96,18 +96,18 @@ module PDD
96
96
  def attrs
97
97
  {
98
98
  'xmlns:xsi' => 'http://www.w3.org/2001/XMLSchema-instance',
99
- 'xsi:noNamespaceSchemaLocation' => "#{host}/xsd/#{PDD::VERSION}.xsd",
99
+ 'xsi:noNamespaceSchemaLocation' => "#{host('xsd')}/#{PDD::VERSION}.xsd",
100
100
  'version' => PDD::VERSION,
101
101
  'date' => Time.now.utc.iso8601
102
102
  }
103
103
  end
104
104
 
105
- def host
106
- 'http://pdd.teamed.io'
105
+ def host(suffix)
106
+ "http://pdd-#{suffix}.teamed.io"
107
107
  end
108
108
 
109
109
  def xsl
110
- "#{host}/xsl/#{PDD::VERSION}.xsl"
110
+ "#{host('xsl')}/#{PDD::VERSION}.xsl"
111
111
  end
112
112
 
113
113
  def render(puzzle, xml)
@@ -121,7 +121,7 @@ module PDD
121
121
 
122
122
  def sanitize(xml)
123
123
  xsd = Nokogiri::XML::Schema(
124
- File.read(File.join(File.dirname(__FILE__), '../asserts/puzzles.xsd'))
124
+ File.read(File.join(File.dirname(__FILE__), '../assets/puzzles.xsd'))
125
125
  )
126
126
  errors = xsd.validate(Nokogiri::XML(xml)).map { |error| error.message }
127
127
  errors.each { |e| PDD.log.error e }
@@ -26,5 +26,5 @@
26
26
  # Copyright:: Copyright (c) 2014 Yegor Bugayenko
27
27
  # License:: MIT
28
28
  module PDD
29
- VERSION = '0.5'
29
+ VERSION = '0.5.1'
30
30
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pdd
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.5'
4
+ version: 0.5.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -248,8 +248,8 @@ files:
248
248
  - LICENSE.txt
249
249
  - README.md
250
250
  - Rakefile
251
- - asserts/puzzles.xsd
252
- - asserts/puzzles.xsl
251
+ - assets/puzzles.xsd
252
+ - assets/puzzles.xsl
253
253
  - bin/pdd
254
254
  - cucumber.yml
255
255
  - features/avoiding_duplicates.feature