bumped version

This commit is contained in:
Yessiest 2023-11-11 20:42:48 +04:00
parent eb7e44a537
commit dce0937e2e
6 changed files with 15 additions and 5 deletions

1
.gitignore vendored
View File

@ -1,3 +1,4 @@
/*.gem
/doc
/.yardoc
/examples/uploader/files/*

View File

@ -2,7 +2,7 @@
Gem::Specification.new do |spec|
spec.name = "landline"
spec.version = "0.10.0"
spec.version = "0.11.0"
spec.summary = "Elegant HTTP DSL"
spec.description = <<~DESC
Landline is a no-hard-dependencies HTTP routing DSL that was made entirely for fun.

View File

@ -10,7 +10,7 @@ require_relative 'landline/template'
# Landline is a hideously simple ruby web framework
module Landline
# Landline version
VERSION = '0.10 "Node graph out of date. Rebuilding..." (beta)'
VERSION = '0.11 "Decades of science" (beta)'
# Landline branding and version
VLINE = "Landline/#{Landline::VERSION} (Ruby/#{RUBY_VERSION}/#{RUBY_RELEASE_DATE})\n".freeze

View File

@ -42,13 +42,13 @@ module Landline
# Set root path (appends matched part of the path).
# @param path [String]
def root(path)
@origin.root = path
@origin.root = File.expand_path(path)
end
# Set root path (without appending matched part).
# @param path [String]
def remap(path)
@origin.remap = path
@origin.remap = File.expand_path(path)
end
# Add a preprocessor to the path.

View File

@ -4,9 +4,16 @@ require_relative 'parseutils'
require_relative 'errors'
require 'date'
require 'openssl'
require 'base64'
HeaderRegexp = Landline::Util::HeaderRegexp
ParserCommon = Landline::Util::ParserCommon
if RUBY_ENGINE == 'jruby' # fix for JRuby
OpenSSL::HMAC.define_singleton_method(:base64digest) do |*args|
Base64.encode64(OpenSSL::HMAC.digest(*args)).strip
end
end
module Landline
# Utility class for handling cookies
class Cookie

View File

@ -48,7 +48,9 @@ module Landline
# @param regexp [Regexp,nil] override param matching regexp
# @return [Array(String, Hash)]
def self.parse_value(input, sep: ";", unquote: false, regexp: nil)
parts = input.split(sep).map { |x| URI.decode_uri_component(x).strip }
parts = input.split(sep).map do |x|
URI.decode_www_form_component(x).strip
end
base = parts.shift
opts = parts.map do |raw|
key, value = raw.match(if regexp