{"id":21313947,"url":"https://github.com/octopusdeploy/octostache","last_synced_at":"2025-04-05T05:02:35.935Z","repository":{"id":28783499,"uuid":"32306189","full_name":"OctopusDeploy/Octostache","owner":"OctopusDeploy","description":"| Public |  The variable substitution syntax for Octopus Deploy","archived":false,"fork":false,"pushed_at":"2025-03-26T02:05:07.000Z","size":423,"stargazers_count":8,"open_issues_count":20,"forks_count":25,"subscribers_count":9,"default_branch":"master","last_synced_at":"2025-03-29T04:03:49.572Z","etag":null,"topics":["public"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/OctopusDeploy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.txt","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":"2015-03-16T06:41:21.000Z","updated_at":"2025-03-11T03:47:42.000Z","dependencies_parsed_at":"2023-02-14T12:15:55.120Z","dependency_job_id":"f66bafbe-ffaf-4f5a-a840-79aaa15d2738","html_url":"https://github.com/OctopusDeploy/Octostache","commit_stats":{"total_commits":260,"total_committers":39,"mean_commits":6.666666666666667,"dds":0.8653846153846154,"last_synced_commit":"6a9cadab2bd51054c1beae194656041e9823627f"},"previous_names":[],"tags_count":78,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctostache","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctostache/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctostache/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/OctopusDeploy%2FOctostache/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/OctopusDeploy","download_url":"https://codeload.github.com/OctopusDeploy/Octostache/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247289409,"owners_count":20914464,"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":["public"],"created_at":"2024-11-21T18:09:26.068Z","updated_at":"2025-04-05T05:02:35.917Z","avatar_url":"https://github.com/OctopusDeploy.png","language":"C#","readme":"Octostache is the variable substitution syntax for Octopus Deploy. \n\nOctopus allows you to [define variables](http://g.octopushq.com/DocumentationVariables), which can then be referenced from deployment steps and in scripts using the following syntax:\n\n```\n#{MyVariable}\n```\n\nThis library contains the code for parsing and evaluating these variable expressions. \n\nUsage is simple: install **Octostache** from NuGet.org, then create a `VariableDictionary`:\n\n```csharp\nvar variables = new VariableDictionary();\nvariables.Set(\"Server\", \"Web01\");\nvariables.Set(\"Port\", \"10933\");\nvariables.Set(\"Url\", \"http://#{Server | ToLower}:#{Port}\");\n\nvar url = variables.Get(\"Url\");               // http://web01:10933\nvar raw = variables.GetRaw(\"Url\");            // http://#{Server | ToLower}:#{Port}\nvar eval = variables.Evaluate(\"#{Url}/foo\");  // http://web01:10933/foo\n```\n\nMore examples can be found in [UsageFixture](https://github.com/OctopusDeploy/Octostache/blob/master/source/Octostache.Tests/UsageFixture.cs). \n\n## Contributing\n🐙 We welcome Pull Requests ❤️🧑‍💻\n\n### Code Cleanup\nThe first stage of our CI/CD pipeline for Octostache runs a ReSharper code cleanup, to keep everything neat and tidy.\n\nYour PR won't be able to pass without ensuring the code is clean. You can do this locally via the [ReSharper CLI tools](https://www.jetbrains.com/help/rider/ReSharper_Command_Line_Tools.html), which is how we enforce it during our builds.\n\nAll the formatting settings are committed to `Octostache.sln.DotSettings`, so as long as you don't override these with an `Octostache.sln.DotSettings.User` file, you should be all good.\n\nTo get started with code cleanup the easiest way (via `dotnet tool`), get the CodeCleanup tool installed globally (one-time):\n```\ndotnet tool install -g JetBrains.ReSharper.GlobalTools\n```\nthen execute the cleanup:\n```\njb cleanupcode ./source/Octostache.sln\n```\n\nWe don't try to enforce this through build scripts or pre-commit hooks, it's up to you to run when you need to. If you use the Rider IDE, it seems to apply another opinion or two when running the code cleanup, and might get different results to the CLI approach; we don't recommend cleaning up this way.\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctopusdeploy%2Foctostache","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foctopusdeploy%2Foctostache","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foctopusdeploy%2Foctostache/lists"}