diff options
-rw-r--r-- | activitypub.rb | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/activitypub.rb b/activitypub.rb index 9a1b9d4..ae3c270 100644 --- a/activitypub.rb +++ b/activitypub.rb @@ -1,10 +1,12 @@ +# frozen_string_literal: true + require 'uri' require 'base64' require 'digest/sha2' require 'sinatra' -USER = "pdp8" -WWW_DOMAIN = "pdp8.info" +USER = 'pdp8' +WWW_DOMAIN = 'pdp8.info' WWW_URL = "https://#{WWW_DOMAIN}" SOCIAL_DOMAIN = "social.#{WWW_DOMAIN}" SOCIAL_DIR = '/srv/social/' @@ -20,11 +22,11 @@ SOCIAL_URL = "https://#{SOCIAL_DOMAIN}" ACTOR = File.join(SOCIAL_URL, USER) enable :sessions -set :session_secret, File.read(".secret").chomp -#set :default_content_type, 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"' -set :default_content_type, 'application/activity+json' +set :session_secret, File.read('.secret').chomp +# set :default_content_type, 'application/ld+json; profile="https://www.w3.org/ns/activitystreams"' +set :default_content_type, 'application/activity+json' set :port, 9292 -require_relative 'helpers.rb' -require_relative 'server.rb' -require_relative 'client.rb' +require_relative 'helpers' +require_relative 'server' +require_relative 'client' |