my xfce4 dotfiles
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

75 lines
3.9 KiB

3 years ago
  1. ## Introduction
  2. > Searches for your frontend web development made easier
  3. ## Installation
  4. Open your `~/.zshrc` file and enable the `frontend-search` plugin:
  5. ```zsh
  6. plugins=( ... frontend-search)
  7. ```
  8. ## Usage
  9. You can use the frontend-search plugin in these two forms:
  10. - `frontend <context> <term> [more terms if you want]`
  11. - `<context> <term> [more terms if you want]`
  12. For example, these two are equivalent:
  13. ```zsh
  14. $ angular dependency injection
  15. # Will turn into ...
  16. $ frontend angular dependency injection
  17. ```
  18. Available search contexts are:
  19. | context | URL |
  20. | ------------- | --------------------------------------------------------------------------- |
  21. | angular | `https://angular.io/?search=` |
  22. | angularjs | `https://google.com/search?as_sitesearch=angularjs.org&as_q=` |
  23. | bem | `https://google.com/search?as_sitesearch=bem.info&as_q=` |
  24. | bootsnipp | `https://bootsnipp.com/search?q=` |
  25. | bundlephobia | `https://bundlephobia.com/result?p=` |
  26. | caniuse | `https://caniuse.com/#search=` |
  27. | codepen | `https://codepen.io/search?q=` |
  28. | compassdoc | `http://compass-style.org/search?q=` |
  29. | cssflow | `http://www.cssflow.com/search?q=` |
  30. | dartlang | `https://api.dartlang.org/apidocs/channels/stable/dartdoc-viewer/dart:` |
  31. | emberjs | `https://www.google.com/search?as_sitesearch=emberjs.com/&as_q=` |
  32. | flowtype | `https://google.com/search?as_sitesearch=flow.org/en/docs/&as_q=` |
  33. | fontello | `http://fontello.com/#search=` |
  34. | github | `https://github.com/search?q=` |
  35. | html5please | `https://html5please.com/#` |
  36. | jestjs | `https://www.google.com/search?as_sitesearch=jestjs.io&as_q=` |
  37. | jquery | `https://api.jquery.com/?s=` |
  38. | lodash | `https://devdocs.io/lodash/index#` |
  39. | mdn | `https://developer.mozilla.org/search?q=` |
  40. | nodejs | `https://www.google.com/search?as_sitesearch=nodejs.org/en/docs/&as_q=` |
  41. | npmjs | `https://www.npmjs.com/search?q=` |
  42. | packagephobia | `https://packagephobia.now.sh/result?p=` |
  43. | qunit | `https://api.qunitjs.com/?s=` |
  44. | reactjs | `https://google.com/search?as_sitesearch=facebook.github.io/react&as_q=` |
  45. | smacss | `https://google.com/search?as_sitesearch=smacss.com&as_q=` |
  46. | stackoverflow | `https://stackoverflow.com/search?q=` |
  47. | typescript | `https://google.com/search?as_sitesearch=www.typescriptlang.org/docs&as_q=` |
  48. | unheap | `http://www.unheap.com/?s=` |
  49. | vuejs | `https://www.google.com/search?as_sitesearch=vuejs.org&as_q=` |
  50. If you want to have another context, open an Issue and tell us!
  51. ## Fallback search behaviour
  52. The plugin will use Google as a fallback if the docs site for a search context does not have a search function. You can set the fallback search engine to DuckDuckGo by setting `FRONTEND_SEARCH_FALLBACK='duckduckgo'` in your `~/.zshrc` file before Oh My Zsh is sourced.
  53. ## Author
  54. **Wilson Mendes (willmendesneto)**
  55. - <https://twitter.com/willmendesneto>
  56. - <https://github.com/willmendesneto>