Skip to content
@Brown-University-Library

Brown University Library

Brown Library GitHub Best practices

Security

Main security message:

Never Commit Sensitive Information — even if the repository is private.

How to reliably do this?

Keep private things out of the github code directory

  • Keep out of code, and the github code directory:

    • passwords
    • API keys
    • server paths
    • database-structure info (where reasonably possible)
    • private settings
    • shell-scripts that set environmental variables
    • log-files (which can sometimes contain sensitive info)
  • Implementation: One common pattern is to have a "project_outer_directory" that contains these things (as well as the "project_code_directory"), and only commit the "project_code_directory" to github.

  • Utilize environment variables: Store sensitive information in environment variables, set outside of the git-directory and thus not able to be accidentally committed. All languages support common ways of doing this.

  • Do not depend on the .gitignore file for security: Rather, get in the habit of thinking of the .gitignore file as keeping messy-unnecessary-cruft out of github (like auto-compiled *.pyc files), not as basic security. Instead, keep the sensitive info out of the github directory in the first place.

Other recommended GitHub practices...

  • Include a README, preferably with an explanation of the repo's Purpose, Usage, and Installation
  • Make it clear which team at BUL "owns" the repo
  • Add a "Description"
  • Include "dependencies" in such a way that github can auto-scan them and notify you of vulnerabilities
  • If you have a dotenv with private info — as noted above it should not be in the repo — but it's useful to have a sample_dotenv.txt file for users to get a sense of what kind of info is required.
  • the main branch is special: it should always work.
  • There should be a "release" for every version of the code actually deployed. (That makes it easier to know which commit to revert back to if there's a problem.)

See also:

This document is a draft & will be undergoing revisions.

Pinned Loading

  1. geodata geodata Public

    Project and open data repo for GeoData@SciLi

  2. bdr_api_documentation bdr_api_documentation Public

    Jupyter Notebook 1

  3. bdr-api-tools bdr-api-tools Public

    Scripts for working with the BDR API.

    Python

  4. django_template_52_project django_template_52_project Public

    Template for new Django projects, full of good-practices -- to get up-and-running easily.

    Python

Repositories

Showing 10 of 260 repositories
  • usep-data Public

    inscriptions and related data files for 'http://library.brown.edu/projects/usep/'

    Brown-University-Library/usep-data’s past year of commit activity
    XSLT 2 25 49 1 Updated Mar 3, 2026
  • bdr_uploader_hub_project Public

    Web-app that allows staff to configure uploader-webapps, and students to upload to them.

    Brown-University-Library/bdr_uploader_hub_project’s past year of commit activity
    Python 0 0 2 6 Updated Feb 28, 2026
  • django-bulstyle Public

    Theme for Brown University Library Django Projects

    Brown-University-Library/django-bulstyle’s past year of commit activity
    CSS 1 0 0 0 Updated Feb 26, 2026
  • Brown-University-Library/ai_inscription_app’s past year of commit activity
    Python 0 MIT 0 6 3 Updated Feb 25, 2026
  • vivo-on-rails Public

    A Ruby on Rails front-end for VIVO

    Brown-University-Library/vivo-on-rails’s past year of commit activity
    Ruby 9 0 2 5 Updated Feb 25, 2026
  • geodata_ossdb Public Forked from frankpd/nyc_geodatabase

    Ocean State Spatial Database: database, documentation, and scripts

    Brown-University-Library/geodata_ossdb’s past year of commit activity
    Jupyter Notebook 6 4 0 1 Updated Feb 25, 2026
  • Brown-University-Library/pdf_checker_project’s past year of commit activity
    Python 0 0 1 0 Updated Feb 25, 2026
  • Brown-University-Library/site_checker_project’s past year of commit activity
    CSS 0 MIT 0 1 2 Updated Feb 25, 2026
  • jira_stories_export_script Public

    script to export current-script stories

    Brown-University-Library/jira_stories_export_script’s past year of commit activity
    Python 0 0 0 0 Updated Feb 21, 2026
  • u2 Public

    make these recently declassified aerial photographs that document the Nile Delta and Nile Valley publicly available via a website that shows their location and how to download them from a digital repository

    Brown-University-Library/u2’s past year of commit activity
    JavaScript 0 0 0 0 Updated Feb 18, 2026

Top languages

Loading…

Most used topics

Loading…