GithubHelp home page GithubHelp logo

fnando / sublime-gem-description Goto Github PK

View Code? Open in Web Editor NEW
2.0 2.0 0.0 158 KB

Show Rubygems description and annotate your code right from Sublime Text.

Python 96.32% Ruby 3.68%
sublime-text rubygems bundler gemfile sublime-text-plugin

sublime-gem-description's Introduction

Gem Description for Sublime Text

Show Rubygems description and annotate your code.

Just mouse over your Gemfile's gem definitions to show the popup.

sublime-gem-description.mp4

Installation

Setup Package Control Repository

  1. Follow the instructions from https://sublime.fnando.com.
  2. Open the command pallete, run “Package Control: Install Package“, then search for “Gem Description“.

Git Clone

Clone this repository into the Sublime Text “Packages” directory, which is located where ever the “Preferences” -> “Browse Packages” option in sublime takes you.

Usage

You can configure this plugin by editing the settings file. You can either open the command palette and search for “Gem Description: Settings” or use “Sublime Text -> Preferences -> Package Settings -> Gem Description -> Settings”. The default settings are:

{
  // The ruby command that will be used.
  // If you use something like asdf, you may need to add the full path, as in
  // "/Users/fnando/.asdf/shims/ruby".
  "command": "ruby",

  // Enable debug mode.
  "debug": false
}

License

Copyright (c) 2021 Nando Vieira

MIT License

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

sublime-gem-description's People

Contributors

fnando avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar

sublime-gem-description's Issues

JSONDecodeError just after installation

Hi, thanks for the package and sorry if this is a dumb issue.

I installed the plugin but can't get it to work. I use asdf and edited the setting mentioned in the README. The stacktrace I get in Sublime console is the following:

Traceback (most recent call last):
  File "/Applications/Sublime Text.app/Contents/MacOS/Lib/python38/sublime_plugin.py", line 1091, in on_hover
    run_view_callbacks('on_hover', view_id, point, hover_zone)
  File "/Applications/Sublime Text.app/Contents/MacOS/Lib/python38/sublime_plugin.py", line 741, in run_view_callbacks
    callback(v, *args)
  File "/Applications/Sublime Text.app/Contents/MacOS/Lib/python38/sublime_plugin.py", line 162, in profiler
    return event_handler(*args)
  File "/Users/bytes/Library/Application Support/Sublime Text 3/Installed Packages/Gem Description.sublime-package/GemDescription.py", line 130, in on_hover
    gem_info = get_gem_info(gem_name)
  File "/Users/bytes/Library/Application Support/Sublime Text 3/Installed Packages/Gem Description.sublime-package/GemDescription.py", line 72, in get_gem_info
    info = fetch_gem_info(gem_name)
  File "/Users/bytes/Library/Application Support/Sublime Text 3/Installed Packages/Gem Description.sublime-package/GemDescription.py", line 65, in fetch_gem_info
    return json.loads(result.stdout.read())
  File "./python3.8/json/__init__.py", line 357, in loads
  File "./python3.8/json/decoder.py", line 337, in decode
  File "./python3.8/json/decoder.py", line 355, in raw_decode
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.