Commit Graph

34 Commits

Author SHA1 Message Date
Patrik Ragnarsson c0ee2c3d84
Rename `master` branch to `main` (#1894)
Related to https://github.com/sinatra/sinatra/issues/1696
2023-03-06 07:43:29 +09:00
Patrik Ragnarsson 65d0ec554c
Update broken links in docs (#1897)
- Rack changed default branch to "main"
- rubydoc.info redirects to https://

[ci skip]
2023-03-05 16:06:56 +01:00
Jordan Owens 6814f2aa67 Deprecate Sinatra Reloader 2022-08-02 15:45:05 -04:00
Eloy Pérez e1eaa9322c Remove support for erubis 2022-02-26 12:26:50 +01:00
Christoph Wagner 00bdf4faee
add QuietLogger that excludes pathes from Rack::CommonLogger (#1250) 2020-03-15 12:25:11 -04:00
tkmru faa09fd879 rm erubi helper and update docs 2018-11-30 18:28:30 +09:00
Olle Jonsson 125df069da README: use the full url in link
- relates to test helpers, engine tracking
  - see #1307
2017-09-09 09:15:17 +02:00
Andreas Finger 0c9343affe Fix links in sinatra-contrib README
The links have been broken. They now point to:
`http://www.sinatrarb.com/contrib/[topic]`

As `test-helpers` and `engine-tracking` are not part of the contrib project, they point to:
`http://www.rubydoc.info/github/sinatra/sinatra-contrib/Sinatra/[topic]`
2017-06-08 11:33:08 +02:00
Zachary Scott 83c099505f Generate and linkify docs for contrib 2017-05-15 17:20:50 -07:00
Zachary Scott 88a1ba7bfb Add build status image to README
Hopefully encourages people to use master until a release is made :trollface:
2016-07-25 13:23:05 +09:00
Zachary Scott 751f2a7a8f Document installing sinatra-contrib from github [ci skip] 2016-07-23 13:41:57 +09:00
Zachary Scott c88158ef0d 💅 [ci skip] 2016-07-20 14:11:17 +09:00
Zachary Scott 4b7709df42 💅 2016-05-23 22:13:57 +09:00
Zachary Scott 3c96ef05ea Remove Sinatra::Decompile API
This extension is obsolete as Sinatra now provides access to a pattern object,
thanks to Mustermann, so that we no longer need to decompose Regexps.

If you're using this API directly, or via an extension that I'm unaware of...
Please let me know and we'll figure something out.

Its highly likely noone was using this extension directly, and possible that
only Namespace was the only consumer via internal usage.

So for now, I'm removing this extension until someone complains.
2016-05-17 22:47:53 +09:00
Zachary Scott bd4fd3f66e Rename Sinatra::Params to Sinatra::RequiredParams
/cc #131
2016-05-04 17:19:29 +09:00
Zachary Scott d8bf344710 Merge pull request #131 from dtaniwaki/add-required-params
Add required params method
2016-05-03 17:30:15 +09:00
yuuji.yaginuma 513917b67e change link to documentation for the latest release 2016-04-21 20:02:31 +09:00
dtaniwaki eb3623ec3c Add required params method 2014-04-20 01:28:49 +09:00
Alexey Chernenkov 36e29bbac6 Add support for custom loggers (controlled via `logger` setting)
CustomLogger extension allows you to define your own logger instance
using +logger+ setting. That logger then will be available
as #logger helper method in your routes and views.

=== Classic Application

To define your custom logger instance in a classic application:

    require 'sinatra'
    require 'sinatra/custom_logger'
    require 'logger'

    set :logger, Logger.new(STDOUT)

    get '/' do
      logger.info 'Some message' # STDOUT logger is used
      # Other code...
    end

=== Modular Application

The same for modular application:

    require 'sinatra/base'
    require 'sinatra/custom_logger'
    require 'logger'

    class MyApp < Sinatra::Base
      helpers Sinatra::CustomLogger

      configure :development, :production do
        logger = Logger.new(File.open("#{root}/log/#{environment}.log", 'a'))
        logger.level = Logger::DEBUG if development?
        set :logger, logger
      end

      get '/' do
        logger.info 'Some message' # File-based logger is used
        # Other code...
      end
    end
2014-03-19 13:14:01 +06:00
Zachary Scott 07bfcfe764 Add links to documentation in README.md [Fixes #101] 2013-08-10 23:14:28 -04:00
Zachary Scott 71ae5e1098 TODO list is already completed 2013-03-25 09:34:50 -04:00
Matthew Conway 066a2a08a4 Fix typo in README 2013-02-07 14:42:34 -08:00
Samy Dindane 904b9889f9 Add installation instructions to the README 2012-09-22 00:59:35 +03:00
Trevor Bramble a85488dc08 Add Travis CI build status to README 2012-06-17 23:42:24 -07:00
Eric Marden b1439a5b39 fixes small omission in one of the examples 2012-02-01 13:02:02 -06:00
Konstantin Haase 57430546e2 add cookies extension 2011-09-04 18:13:40 -07:00
Konstantin Haase 70536c9ff5 add multi route extension 2011-09-04 18:13:27 -07:00
Konstantin Haase f38fc52a8a remove Sinatra::Protection (part of Sinatra now) 2011-09-02 15:01:03 -06:00
Andrew Crump 35d2c0ddb3 Replace csrf example with protection. 2011-08-29 22:45:27 +01:00
Konstantin Haase ec135d109d add ruby highlighting to readme 2011-05-24 19:50:01 +02:00
Konstantin Haase 923e8080af update readme 2011-05-09 08:36:48 +02:00
Konstantin Haase cf6de883d0 move sinatra-decompile to custom extensions 2011-03-30 20:49:11 +02:00
Konstantin Haase c5dcfe24a2 some README 2011-03-29 10:05:12 +02:00
Konstantin Haase 07a649ab6d initial commit 2011-03-24 08:43:39 +01:00