put files in pastebinner dir

This commit is contained in:
booboy 2019-01-28 23:58:30 -06:00
parent cac1352895
commit c72f8c9a5f
4 changed files with 24 additions and 2 deletions

View file

@ -1,6 +1,6 @@
#!/usr/bin/env ruby
require '../lib/pastebinner'
require '../lib/option_parser'
require '../lib/pastebinner/option_parser'
require 'pry'
# setup our object and grab a session key

View file

@ -135,7 +135,7 @@ class Pastebinner
end
def hash_metadata(raw_paste_metadata)
hash_metadata = { "paste_metadata": raw_paste_metadata }
hash_metadata = { "paste_metadata": "#{raw_paste_metadata}" }
end
def hash_doc_type(doc_type)
@ -171,6 +171,19 @@ class Pastebinner
payload: payload)
end
def text_and_metadata(keys)
# keys = self.get_unique_keys
raw_pastes = keys.map do |key|
self.raw_paste_data(key)
end
raw_paste_metadata = keys.map do |key|
self.raw_paste_metadata(key)
end
end
# keep this method private so we are not letting anyone run any method in our program
private
# this will be the main way to execute any of these methods. this has the exception handling taken care of.

View file

@ -0,0 +1,9 @@
class PastebinnerError < StandardError
def InvalidArgument
end
def ConfigError
end
end