{"id":14070841,"url":"https://github.com/vba-blocks/vba-blocks","last_synced_at":"2025-07-30T08:33:07.288Z","repository":{"id":24284517,"uuid":"87371925","full_name":"vba-blocks/vba-blocks","owner":"vba-blocks","description":"A package manager and build tool for VBA","archived":false,"fork":false,"pushed_at":"2023-01-06T01:34:46.000Z","size":75327,"stargazers_count":52,"open_issues_count":30,"forks_count":11,"subscribers_count":8,"default_branch":"main","last_synced_at":"2024-06-18T00:38:25.429Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://vba-blocks.com","language":"VBA","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/vba-blocks.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null},"funding":{"github":["timhall"]}},"created_at":"2017-04-06T01:20:55.000Z","updated_at":"2024-01-28T15:26:40.000Z","dependencies_parsed_at":"2023-01-14T00:42:52.561Z","dependency_job_id":null,"html_url":"https://github.com/vba-blocks/vba-blocks","commit_stats":null,"previous_names":[],"tags_count":14,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vba-blocks%2Fvba-blocks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vba-blocks%2Fvba-blocks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vba-blocks%2Fvba-blocks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/vba-blocks%2Fvba-blocks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/vba-blocks","download_url":"https://codeload.github.com/vba-blocks/vba-blocks/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":215155197,"owners_count":15836926,"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":"2024-08-13T07:08:07.540Z","updated_at":"2024-08-13T07:17:41.748Z","avatar_url":"https://github.com/vba-blocks.png","language":"VBA","funding_links":["https://github.com/sponsors/timhall"],"categories":["VBA"],"sub_categories":[],"readme":"# vba-blocks\n\nA package manager and build tool for VBA.\n\n## Installation\n\n**Windows**\n\nIn powershell, run the following:\n\n```txt\niwr https://vba-blocks.com/install.ps1 | iex\n```\n\n**Mac**\n\nIn terminal, run the following:\n\n```txt\ncurl -fsSL https://vba-blocks.com/install.sh | sh\n```\n\nFor more recent versions of Office for Mac, you will need to trust access to the VBA project object model for vba-blocks to work correctly:\n\n\u003cdetails\u003e\n  \u003csummary\u003eTrust access to the VBA project object model\u003c/summary\u003e\n  \u003col\u003e\n    \u003cli\u003eOpen Excel\u003c/li\u003e\n    \u003cli\u003eClick \"Excel\" in the menu bar\u003c/li\u003e\n    \u003cli\u003eSelect \"Preferences\" in the menu\u003c/li\u003e\n    \u003cli\u003eClick \"Security\" in the Preferences dialog\u003c/li\u003e\n    \u003cli\u003eCheck \"Trust access to the VBA project object model\" in the Security dialog\u003c/li\u003e\n \u003c/ol\u003e\n\u003c/details\u003e\n\nIf you run into any issues during installation, please see the [known issues](https://github.com/vba-blocks/installer#known-issues) for the installer or [create a new issue](https://github.com/vba-blocks/installer/issues/new) with details about what's happening.\n\n:rocket: You're ready to go! Open a new command-line session (cmd / terminal) and try `vba --help`\n\n## Usage\n\n### `new`\n\nCreate a new folder with a blank/generated vba-blocks project inside\n\nCreate a folder \"project-name\" with a blank xlsm project:\n\n```txt\nvba new project-name.xlsm\n```\n\n(equivalent to above)\n\n```txt\nvba new project-name --target xlsm\n```\n\nCreate a folder \"from-existing\" with a project from an existing workbook:\n\n```txt\nvba new from-existing --from existing.xlsm\n```\n\nCreate a blank package for sharing as a library between projects:\n\n```txt\nvba new json-converter --package\n```\n\n### `init`\n\nCreate a blank/generated vba-blocks project in the current folder\n\nCreate a blank xlsm project with the current folder's name:\n\n```txt\nvba init --target xlsm\n```\n\nCreate a project from an existing workbook:\n\n```txt\nvba init --from existing.xlsm\n```\n\nCreate a blank package:\n\n```txt\nvba init --package\n```\n\n### `build`\n\nBuild an Excel workbook from the project's source. The built file is located in the `build/` folder and if a previously built file is found it is moved to `/.backup` to protect against losing any previously saved work.\n\nBuild a project:\n\n```txt\nvba build\n```\n\nBuild and open a project for editing:\n\n```txt\nvba build --open\n```\n\nBuild a package using a blank target:\n\n```txt\nvba build --target xlsm\n```\n\nBuild a project, excluding any development src, dependencies, or references:\n\n```txt\nvba build --release\n```\n\n### `export`\n\nOnce you've completed your edits and are ready to commit your changes, export your project with `vba export`.\n\nExport a project:\n\n```txt\nvba export\n```\n\nExport a previously-built package:\n\n```txt\nvba export --target xlsm\n```\n\n### `run`\n\n`vba run` is a useful utility function for running a public macro in the given workbook, passing up to 10 arguments, and if it returns a string value, outputing it to the console.\n\n```vb\n' (Module: Messages.bas)\nPublic Function SayHi(Name As Variant) As String\n  SayHi = \"Howdy \" \u0026 Name \u0026 \"!\"\nEnd Function\n```\n\n```txt\nvba run Messages.SayHi Tim\nHowdy Tim!\n```\n\n## Manifest (vba-block.toml)\n\n### [project] or [package]\n\n- `name` (_required_)\n- `version` (_required_ for `[package]`)\n- `authors` (_required_ for `[package]`)\n- `target` (_required_ for `[project]`)\n\n```toml\n[project]\nname = \"awesome-excel-project\"\ntarget = \"xlsm\"\n```\n\n```toml\n[package]\nname = \"awesome-vba-package\"\nauthors = [\"Me \u003cme@email.com\u003e\"]\nversion = \"0.1.0\"\n```\n\n### [src]\n\n`name = \"path\"` or\n\n- `path`\n\n```toml\n[src]\nA = \"src/A.bas\"\nB = \"src/B.cls\"\nC = { path = \"src/C.bas\" }\n```\n\n### [dependencies]\n\n`name = \"version\"` or\n\n- `version`\n- `path`\n- `git` (and `branch`, `tag`, or `rev`)\n\n```toml\n[dependencies]\na = \"1\" # Equivalent to ^1\nb = \"=2.0.0\" # Precisely 2.0.0\nc = { version = \"3\" }\n\nd = { path = \"./packages/d\" }\n\ne = { git = \"https://...\" } # master\nf = { git = \"https://...\", branch = \"dev\" }\ng = { git = \"https://\", tag = \"bugfix\" }\nh = { git = \"https://\", rev = \"abc1234\" }\n```\n\n### [references]\n\n- `version` (`\"MAJOR.MINOR\"`)\n- `guid` (`\"{...}\"`)\n\n```toml\n[references]\nScripting = { version = \"1.0\", guid = \"{...}\" }\n```\n\n### [dev-src,dependencies,references]\n\n`[dev-src]`, `[dev-dependencies]`, and `[dev-references]` are included during development and are excluded when building with the `--release` flag (i.e. `vba build --release`)\n\n## Development\n\n### Prerequisites\n\n1. `git clone` this repo\n2. Install [node](https://nodejs.org/) v12.19.0 or later\n3. Install node-gyp dependencies for [Mac](https://github.com/nodejs/node-gyp#on-macos) or [Windows](https://github.com/nodejs/node-gyp#on-windows)\n\n### Build\n\n1. Run `npm install`\n2. Run `npm run build`\n3. Run `npm run build:addins`\n\n### Test\n\n1. Run `npm test`\n2. Run `npm run test:e2e`\n\n### Release\n\n1. Run `npm version`\n2. Run `npm run release`\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvba-blocks%2Fvba-blocks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fvba-blocks%2Fvba-blocks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fvba-blocks%2Fvba-blocks/lists"}