{"id":17598945,"url":"https://github.com/asmega/logput","last_synced_at":"2025-04-30T06:08:22.230Z","repository":{"id":4032906,"uuid":"5133611","full_name":"asmega/logput","owner":"asmega","description":"Rack middleware to output rails logs to a webpage","archived":false,"fork":false,"pushed_at":"2017-08-30T10:09:46.000Z","size":30,"stargazers_count":3,"open_issues_count":0,"forks_count":2,"subscribers_count":0,"default_branch":"master","last_synced_at":"2024-10-29T10:58:48.957Z","etag":null,"topics":["debugging","logging","middleware","rack","rack-middleware","rails","ruby","testing-tools"],"latest_commit_sha":null,"homepage":null,"language":"Ruby","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/asmega.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2012-07-21T12:52:54.000Z","updated_at":"2017-08-30T08:32:26.000Z","dependencies_parsed_at":"2022-08-20T13:00:47.257Z","dependency_job_id":null,"html_url":"https://github.com/asmega/logput","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/asmega%2Flogput","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/asmega%2Flogput/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/asmega%2Flogput/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/asmega%2Flogput/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/asmega","download_url":"https://codeload.github.com/asmega/logput/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250907710,"owners_count":21506069,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["debugging","logging","middleware","rack","rack-middleware","rails","ruby","testing-tools"],"created_at":"2024-10-22T10:08:23.676Z","updated_at":"2025-04-30T06:08:22.199Z","avatar_url":"https://github.com/asmega.png","language":"Ruby","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Logput\n\n[![Build Status](https://api.travis-ci.org/asmega/logput.svg)](https://travis-ci.org/asmega/logput) [![Code Climate](https://codeclimate.com/github/asmega/logput/badges/gpa.svg)](https://codeclimate.com/github/asmega/logput) [![Gem Version](https://badge.fury.io/rb/logput.svg)](https://badge.fury.io/rb/logput)\n\nRack middleware to sit in a rails app to put put the current environments log to a webpage. eg /logput\n\nTo be used in test and development environments to see logs without needing direct access to the box.\n\n:warning: This is *NOT* to be used in production like environments.\n\nSupports Rails 3.x.x and 4.x.x\n\n## Credits\n\n* Phil Lee ([@asmega](https://github.com/asmega)) [Author]\n* Chris Barber ([@chrisbarber86](https://github.com/chrisbarber86))\n\n## Installation\n\nAdd this line to your application's Gemfile:\n\n    gem 'logput'\n\nAnd then execute:\n\n    $ bundle\n\nOr install it yourself as:\n\n    $ gem install logput\n\n## Usage\n\nInside you rails app. Add the following line to config/development.rb and/or any other environment you wish to use this in.\n\n    config.middleware.use(Logput::Middleware)\n\nThe following configuration options are available.\n\n* `:path_to_log_file =\u003e '/path/to/custom/log'`. Defaults to current environments log file if in rails.\n* `:lines_to_read =\u003e 1000`. Defaults to 500.\n\nExample.\n\n    config.middleware.use(Logput::Middleware, :lines_to_read =\u003e 300, :path_to_log_file =\u003e './log/delayed_job')\n\nStart your rails server as normal in the set environment. Navigate to /logput e.g. [http://localhost:3000/logput](http://localhost:3000/logput)\n\n## Environment Variable Overrides\n\nIt is possible to overide the location of the log files by using the following environment variables:\n\n* `LOG_NAME` - The name of the log file, e.g. `development` - `.log` will be appended to this. If unset logput will try to use `RAILS_ENV` or `RACK_ENV` as a fallback\n* `LOG_LOCATION_DIR` - The directory where the log file is located, e.g. `logs` - a `/` will be added when combined with the log name.\n\nThe overrides will only be used if both are present (or the fallbacks in the case of the log name).\n\n## Contributing\n\n1. Fork it\n2. Create your feature branch (`git checkout -b my-new-feature`)\n3. Commit your changes (`git commit -am 'Added some feature'`)\n4. Push to the branch (`git push origin my-new-feature`)\n5. Create new Pull Request\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fasmega%2Flogput","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fasmega%2Flogput","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fasmega%2Flogput/lists"}