Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Code Search with Laravel and Sourcegraph

Code Search with Laravel and Sourcegraph

Learn to navigate and get onboarded to Laravel codebases faster with Sourcegraph. Find code easily with the click of a button!

UnStack Africa, November, 2021

Otemuyiwa Prosper

November 08, 2021
Tweet

More Decks by Otemuyiwa Prosper

Other Decks in Programming

Transcript

  1. Code Search With Laravel & Sourcegraph https://sourcegraph.com/search

  2. Prosper Otemuyiwa Co-founder, Eden Life Developer Advocate, Sourcegraph

  3. Question for you! • How do you currently search for

    open source code? • How do you search for private code? • How do you get code intelligence outside of your local editor?
  4. What is Laravel? https://laravel.com

  5. Laravel - An artisan’s framework • A Full Stack PHP

    Framework • An API Backend • A Vibrant and powerful community • Plethora of developer tools e.g Nova, Cashier, Forge, Envoyer, Valet, Telescope, Scout, Telescope, Sanctum, etc • Educational Platforms e.g Laracasts.com, dailylaravel.com, laravel.io etc
  6. Before we continue...

  7. What’s your Sourcegraph Temperature? • I’ve never heard of it.

    • I’ve heard of it but don’t understand it. • I understand it, but I don’t see how it’s useful. • I see how it could be fun for senior developers, but not for me. • It’s becoming more useful for me. • I use it all the time. • I could not imagine life without it. • Seriously, people are living without it? How?
  8. Enter code search ... https://sourcegraph.com

  9. Sourcegraph - Simple & Advanced Code Search

  10. What is Sourcegraph’s Value To You? • Search over 2.1M

    open source & public repositories across GitHub & Gitlab. • Search private code across several repositories • Precise code intelligence • Automation of large scale code changes via Batch changes. • Code monitoring • Code insights (still in beta)
  11. Sourcegraph - Code Search Patterns • Literal • Regular expression

    • Structural
  12. Sourcegraph Search - Literal

  13. Sourcegraph Search - Literal

  14. Sourcegraph Search - Regular Expression

  15. Sourcegraph Search - Regular Expression

  16. Sourcegraph Search - Regular Expression

  17. Sourcegraph Search - Structural Search

  18. Sourcegraph Search - Structural Search

  19. Use Cases you’ll love ...

  20. Reviewing Pull Request on GitHub - How do I get

    code intelligence easily?
  21. Pull Request on GitHub - Hover information

  22. Pull Request on GitHub - Find All References

  23. Find Secrets & Vulnerabilities in your codebase

  24. Find exact dependencies that may be vulnerable.

  25. Find deprecated function calls in your organization’s codebase.

  26. Recap: Why you need Sourcegraph? • Developer velocity - Help

    all your developers to move fast. With code intelligence & great search, code discovery is a walk in the park. You don’t need to keep cloning repos to effectively search through them! • Onboarding new developers to a codebase - The faster developers can understand your massive codebase, the better. • Codebase refactors (batch changes) - as codebase grows, you need to refactor the codebase more intelligently.
  27. Sourcegraph Search Parameters Recap

  28. Learn more about code search https://learn.sourcegraph.com

  29. Sourcegraph Resources! • learn.sourcegraph.com • docs.sourcegraph.com • dev.to/sourcegraph • about.sourcegraph.com/blog

    • info.sourcegraph.com/dev-tool-time • about.sourcegraph.com/podcast
  30. Twitter: @unicodeveloper GitHub: @unicodeveloper Thank You & Please reach out!