Coder Social home page Coder Social logo

github_codesearch_hack_scripts's Introduction

GitHub Code Search Hack Scripts

A collection of scripts to make working with GitHub Code Search (cs.github.com) easier.

How

Unfortunately, because this solution isn't officially supported, there are a few pieces of API information you'll need to extract manually while interacting with the cs.github.com site.

Using this Project

In order to extract these 'keys' for uses by these scripts, we recommend that your browser's develper tools and inspect the various requests normally made under the 'Network' tab. This information should be put inside of a file named config.yml inside the repositories root directory. This config.yml file is already part of the .gitignore so adding it to this repository will not risk you accidentally committing it.

The format of this config.yml is the following:

github_cs:
    host_blackbird: # From the request cookie `__Host-blackbird`
    login_state:    # From the request cookie `login_state`

Usage Example

Search for Gradle Build Files that are using http:// (instead of https://) for their url in the repositories block:

python code_search.py --all-pages '(" url \"http://" OR "uri(\"http://" OR " url = uri(\"http://") AND ("maven {" OR "maven()" OR "ivy {" OR "ivy()") AND (path:*.gradle OR path:*.gradle.kts)' | jq '.results[] | { repo: .repo_name, path: .path }'

github_codesearch_hack_scripts's People

Contributors

dependabot[bot] avatar jlleitschuh avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

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.