# What Happens When a GitHub User Has No Public Repositories in Resume GitHub

> Learn what happens when a GitHub user has no public repositories on Resume GitHub. Discover the friendly message displayed instead of errors.

- Repository: [GitHub resume generator/resume.github.com](https://github.com/resume/resume.github.com)
- Tags: faq
- Published: 2026-03-04

---

**When a user has no public repositories, the Resume GitHub application displays a friendly message in the Jobs section instead of crashing or rendering empty content.**

The resume.github.com project automatically generates résumés from GitHub profile data. When a user has no public repositories, the application handles this edge case gracefully by injecting an informative notice into the DOM while continuing to render other available profile information.

## How the Application Detects Empty Repository Lists

The detection logic resides in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js). When the `run()` function executes, it invokes `github_user_repos` to fetch repository data from the GitHub API. The callback receives a `data` array containing the user's repositories. If this array is empty, the code identifies that the user has no public repositories available for display.

## The "No Public Repositories" User Experience

### The Conditional Logic in githubresume.js

Inside the `run()` function at lines 48-53, the application checks the length of the repository data array. When the array is empty, execution flows into a dedicated branch that handles the absence of public repositories. This branch targets the DOM element with the ID `#jobs`, which normally displays the user's projects and employment history derived from repository data.

### The Friendly Message Displayed to Visitors

Instead of leaving the section blank, the script injects a user-friendly paragraph into the `#jobs` container. The message reads: "Unfortunately, this user does not seem to have any **public** repositories." This notice clearly communicates to visitors that the GitHub account exists but contains no publicly visible code, while the rest of the résumé sections—such as profile information, languages, and organizations—continue to render normally if data is available.

## Code Implementation Details

The core functionality spans two primary files. The [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js) file contains the `run()` function that orchestrates data fetching and DOM manipulation. The [`views/job.html`](https://github.com/resume/resume.github.com/blob/main/views/job.html) file provides the template structure for the Jobs section, though the "no repos" message is dynamically inserted via JavaScript rather than residing in the static template.

When `github_user_repos` returns an empty result, the following logic executes:

```javascript
// Simplified representation of the logic in js/githubresume.js
if (data.length === 0) {
    $('#jobs').html('').append(
        '<p class="enlarge">' +
        'Unfortunately, this user does not seem to have any <strong>public</strong> repositories.' +
        '</p>'
    );
}

```

This approach ensures that the application degrades gracefully without JavaScript errors or broken UI elements.

## Customizing the Empty Repository Message

Developers deploying their own instance of Resume GitHub can modify the notification text. To customize the message, edit the HTML string within the `else` block of the `run()` function in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js).

For example, to add a link to the user's GitHub profile:

```javascript
$('#jobs').html('').append(
    '<p class="enlarge">Unfortunately, this user does not seem to have any <strong>public</strong> repositories. ' +
    '<a href="https://github.com/' + username + '">Visit their GitHub profile</a> to verify.</p>'
);

```

After modifying the file and redeploying, users without public repositories will see your customized message instead of the default text.

## Summary

- The Resume GitHub application handles users with no public repositories by displaying a friendly message in the Jobs section rather than crashing or showing blank content.
- Detection occurs in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js) when the `github_user_repos` callback returns an empty data array, triggering the logic at lines 48-53.
- The message "Unfortunately, this user does not seem to have any **public** repositories" is injected into the `#jobs` DOM element, while other résumé sections continue to render normally.
- Developers can customize this behavior by modifying the HTML string in the `run()` function to provide different messaging or additional links.

## Frequently Asked Questions

### Does Resume GitHub crash if a user has no public repositories?

No, the application does not crash. The `run()` function in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js) specifically checks for empty repository data and executes a dedicated code branch that displays an informative message to the visitor.

### Which section of the résumé displays the "no public repos" message?

The message appears in the **Jobs** section, which corresponds to the DOM element with the ID `#jobs`. This section normally lists the user's repositories and project history, but is replaced with the notice when no public repositories exist.

### Can I customize the message shown when a user has no public repositories?

Yes, you can customize the message by editing the HTML string inside the `else` block of the `run()` function in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js). You can modify the text, add CSS classes, or include links to the user's GitHub profile.

### Where is the logic that checks for empty repositories located?

The conditional logic resides in [`js/githubresume.js`](https://github.com/resume/resume.github.com/blob/main/js/githubresume.js) within the `run()` function, specifically around lines 48-53. This code checks if the `data` array returned by `github_user_repos` has a length of zero, indicating no public repositories are available.