pdf4me 1.0.0 → 1.0.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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 913225dfa467f836d3c11a20aff2ca56debcd92c
4
- data.tar.gz: 37610fb0a739b216a951172a9b847f11a6b5f9d2
3
+ metadata.gz: 431d852c1c429c6d2f4197af206dca26c866cbfd
4
+ data.tar.gz: 522eb046ccbece19c09f9f768734f26842df365d
5
5
  SHA512:
6
- metadata.gz: c311ac1567c9d7d4831e61ad770352ac33da85bb6dfcc9d1ff4cab8c008b3cb60dbc5282d292052fe24c08dbe1acbc35470788e19534544662516a7378d15e64
7
- data.tar.gz: 76acc2bf0daf9cad1024230463291c2f5bd77ae2f105874a3647abde647b2ae689b1efe828e94c0b0841ee9d65a63cf0f8cf7f7950d1711e7754d3ace2e4edc0
6
+ metadata.gz: f7ecb848b188c207e5f55efcaafd3e9a215a5da2e4eb5363db3778e082b2fc6248a6b59a4a28af3a3d8f115e452209f2628a4f6412d1378a7ce1b1bfee724000
7
+ data.tar.gz: d8bd4e8e19c5c44b4375f827a4dfcf46de25deff2137742bbf0330d5035704ad6d2e17e9bc15a1f85cdc71ddc4c708e956b68fc0c464772a42eb4341b2c64954
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2018 pdf4me
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md CHANGED
@@ -19,11 +19,24 @@ bundle install
19
19
  gem install pdf4me
20
20
  ```
21
21
 
22
+ ## Build locally/for development
23
+ To build the Ruby code into a gem:
24
+
25
+ ```shell
26
+ gem build pdf4me.gemspec
27
+ ```
28
+
29
+ Then either install the gem locally:
30
+
31
+ ```shell
32
+ gem install ./pdf4me-1.0.0.gem
33
+ ```
34
+
22
35
  ## Install from Git
23
36
 
24
- You can also install from a git repository: https://github.com/GIT_USER_ID/GIT_REPO_ID.git, then add the following in the Gemfile:
37
+ You can also install from a git repository: https://github.com/pdf4me/pdf4me-clientapi-ruby.git, then add the following in the Gemfile:
25
38
 
26
- gem 'pdf4me', :git => 'https://github.com/GIT_USER_ID/GIT_REPO_ID.git'
39
+ gem 'pdf4me', :git => 'https://github.com/pdf4me/pdf4me-clientapi-ruby.git'
27
40
 
28
41
  ## Initializing Pdf4me
29
42
  Pdf4me works with any Rack application or plain old ruby script. In any regular script the configuration of Pdf4me looks like
@@ -117,7 +117,13 @@ module Pdf4me
117
117
  # Custom attribute writer method checking allowed values (enum).
118
118
  # @param [Object] doc_log_level Object to be assigned
119
119
  def doc_log_level=(doc_log_level)
120
- validator = EnumAttributeValidator.new('String', ["verbose", "info", "warning", "error", "timing"])
120
+ log_levels = %w|verbose info warning error timing|
121
+
122
+ if doc_log_level.to_s.match(/\d+/)
123
+ doc_log_level = log_levels[doc_log_level.to_i]
124
+ end
125
+
126
+ validator = EnumAttributeValidator.new('String', log_levels)
121
127
  unless validator.valid?(doc_log_level)
122
128
  fail ArgumentError, "invalid value for 'doc_log_level', must be one of #{validator.allowable_values}."
123
129
  end
@@ -11,5 +11,5 @@ Swagger Codegen version: 2.3.0
11
11
  =end
12
12
 
13
13
  module Pdf4me
14
- VERSION = "1.0.0"
14
+ VERSION = "1.0.1"
15
15
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pdf4me
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - themonk
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-05-17 00:00:00.000000000 Z
11
+ date: 2018-10-30 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: typhoeus
@@ -212,6 +212,7 @@ extensions: []
212
212
  extra_rdoc_files: []
213
213
  files:
214
214
  - Gemfile
215
+ - LICENSE
215
216
  - README.md
216
217
  - Rakefile
217
218
  - docs/ActionFlow.md
@@ -300,7 +301,6 @@ files:
300
301
  - docs/UserFingerprint.md
301
302
  - docs/VersionRes.md
302
303
  - docs/java.md
303
- - git_push.sh
304
304
  - lib/pdf4me.rb
305
305
  - lib/pdf4me/api/convert_api.rb
306
306
  - lib/pdf4me/api/document_api.rb
@@ -1,55 +0,0 @@
1
- #!/bin/sh
2
- #
3
- # Generated by: https://github.com/swagger-api/swagger-codegen.git
4
- #
5
- # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
6
- #
7
- # Usage example: /bin/sh ./git_push.sh wing328 swagger-petstore-perl "minor update"
8
-
9
- git_user_id=$1
10
- git_repo_id=$2
11
- release_note=$3
12
-
13
- if [ "$git_user_id" = "" ]; then
14
- git_user_id="GIT_USER_ID"
15
- echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
16
- fi
17
-
18
- if [ "$git_repo_id" = "" ]; then
19
- git_repo_id="GIT_REPO_ID"
20
- echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
21
- fi
22
-
23
- if [ "$release_note" = "" ]; then
24
- release_note="Minor update"
25
- echo "[INFO] No command line input provided. Set \$release_note to $release_note"
26
- fi
27
-
28
- # Initialize the local directory as a Git repository
29
- git init
30
-
31
- # Adds the files in the local repository and stages them for commit.
32
- git add .
33
-
34
- # Commits the tracked changes and prepares them to be pushed to a remote repository.
35
- git commit -m "$release_note"
36
-
37
- # Sets the new remote
38
- git_remote=`git remote`
39
- if [ "$git_remote" = "" ]; then # git remote not defined
40
-
41
- if [ "$GIT_TOKEN" = "" ]; then
42
- echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
43
- git remote add origin https://github.com/${git_user_id}/${git_repo_id}.git
44
- else
45
- git remote add origin https://${git_user_id}:${GIT_TOKEN}@github.com/${git_user_id}/${git_repo_id}.git
46
- fi
47
-
48
- fi
49
-
50
- git pull origin master
51
-
52
- # Pushes (Forces) the changes in the local repository up to the remote repository
53
- echo "Git pushing to https://github.com/${git_user_id}/${git_repo_id}.git"
54
- git push origin master 2>&1 | grep -v 'To https'
55
-