URL Structure for Generating a Resume: The Complete Guide to resume.github.com

To generate a resume, append the GitHub username as the sole query string parameter without a key, using the format https://resume.github.io/?<github-username>.

The resume.github.com project provides a client-side service that transforms public GitHub data into polished HTML résumés. Understanding the URL structure for generating a resume is essential for both users sharing their profiles and developers deploying self-hosted instances. This guide examines the exact URL format, parsing logic, and implementation details found in the source code.

The Basic URL Structure for Resume Generation

The service expects a single query string parameter that contains only the GitHub username, omitting the traditional key-value pair structure. This design creates clean, shareable URLs that require no additional configuration.


https://resume.github.io/?defunkt

This URL loads the résumé for the GitHub user defunkt. The same pattern applies to any self-hosted deployment, such as https://my-domain.com/?alice.

How the URL Parameter Is Parsed

The client-side application extracts the username from the query string using a regular expression that treats the first parameter as the username value, regardless of whether it includes an equals sign.

Client-Side Parsing in githubresume.js

In js/githubresume.js, the parsing logic iterates through the query string and captures the first parameter:

var urlParams = {};
var r = /([^&=]+)=?([^&]*)/g,
    q = window.location.search.substring(1);
while (e = r.exec(q)) {
   urlParams[0] = decodeURIComponent(e[1].replace(/\+/g, " "));
}
if (urlParams[0] !== undefined) {
    username = urlParams[0];
    run();
}

This code stores the decoded username in urlParams[0] and triggers the run() function to fetch data from the GitHub API.

Generating Resume URLs Programmatically

While manual URL construction works for simple sharing, the application also provides a form-based interface and supports automated generation for custom deployments.

Using the Built-in Form

The home page at views/index.html includes a form that constructs the URL dynamically:

<form id="run" action="." method="get">
  <input id="username" type="text" placeholder="Enter your GitHub username">
  <button type="submit">Generate</button>
</form>

<script>
$(document).ready(function() {
    $('form#run').submit(function(e){
        var genUser = $('#username').val();
        document.location = document.location.pathname + "?" + genUser;
        e.preventDefault();
    });
});
</script>

When submitted, this script prevents the default form action and redirects to ?<username>, maintaining the required URL structure.

Self-Hosted Deployments

For private instances, the same URL pattern applies regardless of domain:


https://resume.company.internal/?jsmith

The application reads the query string identically, making it compatible with any hosting environment without configuration changes.

From URL to Rendered Resume

Once the username is extracted, the application fetches public GitHub data via the API and renders the résumé using Mustache templates. The system selects between views/resume.html for individual users and views/resumeOrgs.html for organization accounts, populating the template with repository statistics, language breakdowns, and contribution data retrieved based on the URL parameter.

Summary

  • The URL structure for generating a resume requires a single query string parameter containing only the GitHub username, formatted as https://resume.github.io/?username.
  • The client-side parser in js/githubresume.js extracts the username by reading the first URL parameter without requiring a key-value pair.
  • Both manual URL construction and the built-in form in views/index.html generate the same query string format.
  • The application supports self-hosted deployments using identical URL patterns, rendering résumés through Mustache templates based on the parsed username.

Frequently Asked Questions

Do I need to include a key in the query string?

No. The URL structure for generating a resume intentionally omits the key typically used in query parameters. You should provide only the username immediately after the question mark, such as ?defunkt rather than ?user=defunkt. The parser in js/githubresume.js specifically treats the first parameter value as the username regardless of whether an equals sign is present.

Can I use this URL structure on my own domain?

Yes. The application is designed to work with any domain without modification. Whether you deploy to https://resume.company.com or a local development server, the URL structure remains identical: append ? followed by the GitHub username. The client-side JavaScript reads window.location.search universally, making the implementation domain-agnostic.

What happens if I visit the URL without a username?

If you access the base URL without any query parameters, the application displays the landing page defined in views/index.html rather than a résumé. This page contains the input form where visitors can enter a username to generate the proper URL structure. The run() function that fetches GitHub data only executes when urlParams[0] contains a defined value.

Which file handles the URL parsing logic?

The URL parsing logic is contained entirely within js/githubresume.js. Specifically, lines 8 through 14 implement a regular expression that iterates through the query string and extracts the first parameter as the username. This file also manages the subsequent API calls to GitHub and coordinates the rendering process using Mustache templates.

Have a question about this repo?

These articles cover the highlights, but your codebase questions are specific. Give your agent direct access to the source. Share this with your agent to get started:

Share the following with your agent to get started:
curl -s "https://instagit.com/install.md"

Works with
Claude Codex Cursor VS Code OpenClaw Any MCP Client

Maintain an open-source project? Get it listed too →