{"id":25836064,"url":"https://github.com/bugsplat-git/symbol-upload","last_synced_at":"2025-03-01T01:39:01.211Z","repository":{"id":46028419,"uuid":"352404860","full_name":"BugSplat-Git/symbol-upload","owner":"BugSplat-Git","description":"Cross-platform symbol upload utility","archived":false,"fork":false,"pushed_at":"2024-04-19T00:03:56.000Z","size":6190,"stargazers_count":10,"open_issues_count":4,"forks_count":3,"subscribers_count":5,"default_branch":"main","last_synced_at":"2024-05-01T11:28:43.276Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/BugSplat-Git.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2021-03-28T18:18:40.000Z","updated_at":"2024-05-16T03:23:22.527Z","dependencies_parsed_at":"2023-10-03T16:36:24.016Z","dependency_job_id":"3f8e875e-34e0-402a-b1be-23ceb6dff927","html_url":"https://github.com/BugSplat-Git/symbol-upload","commit_stats":{"total_commits":101,"total_committers":2,"mean_commits":50.5,"dds":0.01980198019801982,"last_synced_commit":"de0980652679cd0f987417709084b5d2e6dd5429"},"previous_names":[],"tags_count":53,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BugSplat-Git%2Fsymbol-upload","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BugSplat-Git%2Fsymbol-upload/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BugSplat-Git%2Fsymbol-upload/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/BugSplat-Git%2Fsymbol-upload/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/BugSplat-Git","download_url":"https://codeload.github.com/BugSplat-Git/symbol-upload/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":241304300,"owners_count":19941100,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-01T01:39:00.596Z","updated_at":"2025-03-01T01:39:01.199Z","avatar_url":"https://github.com/BugSplat-Git.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"[![bugsplat-github-banner-basic-outline](https://user-images.githubusercontent.com/20464226/149019306-3186103c-5315-4dad-a499-4fd1df408475.png)](https://bugsplat.com)\n\u003cbr/\u003e\n# \u003cdiv align=\"center\"\u003eBugSplat\u003c/div\u003e \n### **\u003cdiv align=\"center\"\u003eCrash and error reporting built for busy developers.\u003c/div\u003e**\n\u003cdiv align=\"center\"\u003e\n    \u003ca href=\"https://twitter.com/BugSplatCo\"\u003e\n        \u003cimg alt=\"Follow @bugsplatco on Twitter\" src=\"https://img.shields.io/twitter/follow/bugsplatco?label=Follow%20BugSplat\u0026style=social\"\u003e\n    \u003c/a\u003e\n    \u003ca href=\"https://discord.gg/bugsplat\"\u003e\n        \u003cimg alt=\"Join BugSplat on Discord\" src=\"https://img.shields.io/discord/664965194799251487?label=Join%20Discord\u0026logo=Discord\u0026style=social\"\u003e\n    \u003c/a\u003e\n\u003c/div\u003e\n\n\u003cbr/\u003e\n\n# symbol-upload\n\nThis repo is a simple Node.js utility, set of libraries, and GitHub action for uploading symbol files or source maps to [BugSplat](https://www.bugsplat.com). This utility is designed to be used in your build process to upload symbols to BugSplat automatically for each production build. This package can be used as a library or a command line utility.\n\n## Action\n\nUse the `symbol-upload` action in your [GitHub Actions](https://github.com/features/actions) workflow by modifying the following snippet.\n\n```yml\n- name: Symbols 📦\n    uses: BugSplat-Git/symbol-upload@main\n    with:\n      clientId: \"${{ secrets.SYMBOL_UPLOAD_CLIENT_ID }}\"\n      clientSecret: \"${{ secrets.SYMBOL_UPLOAD_CLIENT_SECRET }}\"\n      database: \"${{ secrets.BUGSPLAT_DATABASE }}\"\n      application: \"your-application\"\n      version: \"your-version\"\n      files: \"**/*.{pdb,exe,dll}\"\n      directory: \"your-build-directory\"\n      node-version: \"22\"\n      dumpSyms: false\n```\n\nBe sure to use [secrets](https://docs.github.com/en/actions/security-guides/using-secrets-in-github-actions) so that you don't expose the values for `clientId`, `clientSecret`, and `database`.\n\n## Command Line\n\n1. Install this package globally `npm i -g @bugsplat/symbol-upload`\n2. Run symbol-upload with `-h` to see the latest usage information and package version:\n\n```bash\nbobby@BugSplat % ~ % symbol-upload -h\n\n@bugsplat/symbol-upload v10.1.0\n\n  symbol-upload contains a command line utility and a set of libraries to help  \n  you upload symbol files to BugSplat.                                          \n\nUsage\n\n  -h, --help                             Print this usage guide.                                                       \n  -b, --database string                  Your BugSplat database name. The value of database must match the value used  \n                                         to post crash reports. This value can also be provided via the                \n                                         BUGSPLAT_DATABASE environment variable.                                       \n  -a, --application string               The name of your application. The value of application must match the value   \n                                         used to post crash reports. If not provided symbol-upload will attempt to use \n                                         the value of the name field in package.json if it exists in the current       \n                                         working directory.                                                            \n  -v, --version string                   Your application's version. The value of version must match the value used to \n                                         post crash reports. If not provided symbol-upload will attempt to use the     \n                                         value of the version field in package.json if it exists in the current        \n                                         working directory.                                                            \n  -u, --user string (optional)           The email address used to log into your BugSplat account. If provided         \n                                         --password must also be provided. This value can also be provided via the     \n                                         SYMBOL_UPLOAD_USER environment variable.                                      \n  -p, --password string (optional)       The password for your BugSplat account. If provided --user must also be       \n                                         provided. This value can also be provided via the SYMBOL_UPLOAD_PASSWORD      \n                                         environment variable.                                                         \n  -i, --clientId string (optional)       An OAuth2 Client Credentials Client ID for the specified database. If         \n                                         provided --clientSecret must also be provided. This value can also be         \n                                         provided via the SYMBOL_UPLOAD_CLIENT_ID environment variable.                \n  -s, --clientSecret string (optional)   An OAuth2 Client Credentials Client Secret for the specified database. If     \n                                         provided --clientId must also be provided. This value can also be provided    \n                                         via the SYMBOL_UPLOAD_CLIENT_SECRET environment variable.                     \n  -r, --remove                           Removes symbols for a specified database, application, and version. If this   \n                                         option is provided no other actions are taken.                                \n  -f, --files string (optional)          Glob pattern that specifies a set of files to upload. Defaults to '*.js.map'  \n  -d, --directory string (optional)      Path of the base directory used to search for symbol files. This value will   \n                                         be combined with the --files glob. Defaults to '.'\n  -m, --dumpSyms boolean (optional)      Use dump_syms to generate and upload sym files for specified binaries.                              \n\n  The -u and -p arguments are not required if you set the environment variables \n  SYMBOL_UPLOAD_USER and SYMBOL_UPLOAD_PASSWORD, or provide a clientId and      \n  clientSecret.                                                                 \n                                                                                \n  The -i and -s arguments are not required if you set the environment variables \n  SYMBOL_UPLOAD_CLIENT_ID and SYMBOL_UPLOAD_CLIENT_SECRET, or provide a user    \n  and password.                                                                 \n\nExample\n\n  symbol-upload -b your-bugsplat-database -a your-application-name -v your-     \n  version [ -f \"*.js.map\" -d \"/path/to/containing/dir\" [ -u your-bugsplat-email \n  -p your-bugsplat-password ] OR [ -i your-client-id -s your-client-secret] ]   \n\nLinks\n\n  🐛 https://bugsplat.com                          \n                                                   \n  💻 https://github.com/BugSplat-Git/symbol-upload \n                                                   \n  💌 support@bugsplat.com   \n```\n3. Run symbol-upload specifying a [glob](https://www.npmjs.com/package/glob#glob-primer) pattern for `-f` and a path with forward slashes for `-d`. Multiple file types can be specified in curly brackets separated by a comma, and wildcards can be used to search directories recursively. For example, `**/*.{pdb,exe,dll}` will search for all `.pdb`, `.exe`, and `.dll` files in the current directory and all subdirectories. Optionally, you can specify the `-m` flag to run [dump_syms](https://github.com/BugSplat-Git/node-dump-syms) against the specified binaries and upload the resulting `.sym` files.\n\n## API\n\n1. Install this package locally `npm i @bugsplat/symbol-upload`.\n2. Import `BugSplatApiClient` and `VersionsApiClient` from @bugsplat/symbol-upload. Alternatively, you can import `OAuthClientCredentialsClient` if you'd prefer to authenticate with an [OAuth2 Client Credentials](https://docs.bugsplat.com/introduction/development/web-services/oauth2#client-credentials) Client ID and Client Secret.\n\n```ts\nimport { BugSplatApiClient, OAuthClientCredentialsClient, uploadSymbolFiles } from '@bugsplat/symbol-upload';\n```\n\n3. Create a new instance of `BugSplatApiClient` using the `createAuthenticatedClientForNode` async factory function or `OAuthClientCredentialsClient` using the `createAuthenticatedClient` async factory function.\n\n```ts\nconst bugsplat = await BugSplatApiClient.createAuthenticatedClientForNode(email, password);\n```\n\n```ts\nconst bugsplat = await OAuthClientCredentialsClient.createAuthenticatedClient(clientId, clientSecret);\n```\n\n4. Upload your symbol files to bugsplat by calling the `uploadSymbolFiles` function.\n\n```ts\nconst directory = '/path/to/symbols/dir';\nconst files = ['my-cool-app.exe', 'my-cool-app.pdb'];\nawait uploadSymbolFiles(bugsplat, database, application, version, directory, files);\n```\n\nIf you've done everything correctly, your symbols should be shown by clicking the application link on the [Versions](https://app.bugsplat.com/v2/versions) page.\n\n\u003cimg width=\"1728\" alt=\"image\" src=\"https://github.com/BugSplat-Git/symbol-upload/assets/2646053/7314bd36-05db-4188-89e4-10f4e7442cec\"\u003e\n\nThanks for using BugSplat!\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbugsplat-git%2Fsymbol-upload","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbugsplat-git%2Fsymbol-upload","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbugsplat-git%2Fsymbol-upload/lists"}