Giter Club home page Giter Club logo

giphy-anywhere's Introduction

GIPHY Anywhere

Sometimes you're composing a chat message or commenting on a pull request, and the need to insert a gif strikes, but opening a new browser window would totally break your flow. GIPHY Anywhere to the rescue!

GIPHY Anywhere is a status bar item which allows you to quickly browse GIPHY for gifs.

Installation

GIPHY Anywhere requires macOS, and is installed using Homebrew:

brew cask install bacongravy/tap/giphy-anywhere

Open GIPHY Anywhere and the GIPHY icon will appear in the system menu bar. It will remain there across logouts and restarts until the status bar item is quit.

Usage

Whenever the urge to gif strikes, open GIPHY Anywhere by clicking on the GIPHY icon in the system menu bar, search or browse for a gif to fit your mood, and then copy the URL of the found gif using one of the menu items. You can copy either the plain URL, ready for sending in a chat message, or the URL wrapped in Markdown, ready for insertion in a GitHub comment. Once you've copied, just paste and go.

Acknowledgements

Huge thanks to GIPHY for providing a great service. This project is not affiliated with GIPHY in any way.

This project was inspired by https://github.com/cknadler/vim-anywhere, and by the rich gif culture at my place of work.

Why?

I use the GIPHY keyboard on iOS every day, and I miss it whenever I'm using macOS. Seeing vim-anywhere on Hacker News gave me the motivation to solve my problem in a similar way. After prototyping a solution using an Automator workflow service and gathering feedback, I rewrote the project as a JavaScript for Automation (JXA) applet to provide a more reliable and consistent user experience across applications. When JXA stopped working in Mojave, I rewrote the project in Swift 4.

giphy-anywhere's People

Contributors

bacongravy avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

er0ck

giphy-anywhere's Issues

Crash on launch on Mojave

The applet crashes on launch on Mojave. This appears in the crashlog:

*** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: 'NSGetSizeAndAlignment(): unsupported type encoding spec 'G' at 'GPoint}"size"{CGSize}}' in '{CGPoint}"size"{CGSize}}''

It appears that, starting in Mojave, any use of a function or method in JavaScript for Automation that takes an NSRect argument (such as NSMakeRect() or -initWithFrame:) results in this crash.

Some gif URLs can't be copied

The gif at https://giphy.com/gifs/jKaFXbKyZFja0 is not recognized by giphy-anywhere as a gif whose URL can be copied.

Crash on Mojave upon installing

After installing cask this message appears:

Error on line 6: Error: An error occurred. (-1743)

Tried re-installing with the same result.

Applet sometimes crashes upon dismissal of the menu

If you click around a bunch on different gifs, copy one, dismiss the menu, re-open it, dissmiss it without copying, repeat with variations, eventually you can get the applet to crash.

Application Specific Information:
objc_msgSend() selector name: release


Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
0   libobjc.A.dylib               	0x00007fffd32e205d objc_msgSend + 29
1   com.apple.AppKit              	0x00007fffbc6b23e8 +[NSStatusBarButtonCell _endTrackingNavigationLoopOnMenu:withToken:view:] + 33
2   com.apple.AppKit              	0x00007fffbc6b289d +[NSStatusBarButtonCell popupStatusBarMenu:inRect:ofView:withEvent:] + 1102
3   com.apple.AppKit              	0x00007fffbc6b6cb0 -[NSStatusItem popUpStatusItemMenu:] + 177

Download the full crash log here.

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.