<html><head><meta name="color-scheme" content="light dark"></head><body><pre style="word-wrap: break-word; white-space: pre-wrap;">"use strict";(self.webpackChunkpantsbuild_org=self.webpackChunkpantsbuild_org||[]).push([[882362],{440144:(e,s,r)=&gt;{r.r(s),r.d(s,{assets:()=&gt;a,contentTitle:()=&gt;l,default:()=&gt;j,frontMatter:()=&gt;c,metadata:()=&gt;d,toc:()=&gt;h});var o=r(474848),t=r(28453),n=r(142519),i=r(87598);const c={title:"scrooge",description:"The Scrooge Thrift IDL compiler (https://twitter.github.io/scrooge/).\n"},l=void 0,d={id:"reference/subsystems/scrooge",title:"scrooge",description:"The Scrooge Thrift IDL compiler (https://twitter.github.io/scrooge/).\n",source:"@site/versioned_docs/version-2.25/reference/subsystems/scrooge.mdx",sourceDirName:"reference/subsystems",slug:"/reference/subsystems/scrooge",permalink:"/stable/reference/subsystems/scrooge",draft:!1,unlisted:!1,tags:[],version:"2.25",frontMatter:{title:"scrooge",description:"The Scrooge Thrift IDL compiler (https://twitter.github.io/scrooge/).\n"},sidebar:"referenceSidebar",previous:{title:"scc",permalink:"/stable/reference/subsystems/scc"},next:{title:"semgrep",permalink:"/stable/reference/subsystems/semgrep"}},a={},h=[{value:"Basic options",id:"basic-options",level:2},{value:"Advanced options",id:"advanced-options",level:2},{value:"&lt;code&gt;artifacts&lt;/code&gt;",id:"artifacts",level:3},{value:"&lt;code&gt;jvm_options&lt;/code&gt;",id:"jvm_options",level:3},{value:"&lt;code&gt;lockfile&lt;/code&gt;",id:"lockfile",level:3},{value:"&lt;code&gt;version&lt;/code&gt;",id:"version",level:3},{value:"Deprecated options",id:"deprecated-options",level:2},{value:"Related subsystems",id:"related-subsystems",level:2}];function p(e){const s={a:"a",code:"code",h2:"h2",h3:"h3",hr:"hr",p:"p",...(0,t.R)(),...e.components};return(0,o.jsxs)(o.Fragment,{children:[(0,o.jsx)(s.hr,{}),"\n",(0,o.jsxs)(s.p,{children:["The Scrooge Thrift IDL compiler (",(0,o.jsx)(s.a,{href:"https://twitter.github.io/scrooge/",children:"https://twitter.github.io/scrooge/"}),")."]}),"\n",(0,o.jsxs)(s.p,{children:["Backend: ",(0,o.jsx)("span",{className:"color--primary",children:(0,o.jsx)(s.code,{children:"pants.backend.experimental.codegen.thrift.scrooge.scala"})})]}),"\n",(0,o.jsxs)(s.p,{children:["Config section: ",(0,o.jsx)("span",{className:"color--primary",children:(0,o.jsx)(s.code,{children:"[scrooge]"})})]}),"\n",(0,o.jsxs)("span",{className:i.A.options,children:[(0,o.jsx)(s.h2,{id:"basic-options",children:"Basic options"}),(0,o.jsx)(s.p,{children:"None"}),(0,o.jsx)(s.h2,{id:"advanced-options",children:"Advanced options"}),(0,o.jsx)(s.h3,{id:"artifacts",children:(0,o.jsx)(s.code,{children:"artifacts"})}),(0,o.jsx)(n.A,{cli_repr:"--scrooge-artifacts=\"['&lt;str&gt;', '&lt;str&gt;', ...]\"",env_repr:"PANTS_SCROOGE_ARTIFACTS",toml_repr:"[scrooge]\nartifacts = [\n    '&lt;str&gt;',\n    '&lt;str&gt;',\n    ...,\n]",default_repr:'[\n  "com.twitter:scrooge-generator_2.13:{version}"\n]',children:(0,o.jsxs)(s.p,{children:["Artifact requirements for this tool using specified as either the address of a ",(0,o.jsx)(s.code,{children:"jvm_artifact"})," target or, alternatively, as a colon-separated Maven coordinates (e.g., ",(0,o.jsx)(s.code,{children:"group:name:version"}),"). For Maven coordinates, the string ",(0,o.jsx)(s.code,{children:"{version}"})," version will be substituted with the value of the ",(0,o.jsx)(s.code,{children:"[scrooge].version"})," option."]})}),(0,o.jsx)(s.h3,{id:"jvm_options",children:(0,o.jsx)(s.code,{children:"jvm_options"})}),(0,o.jsxs)(n.A,{cli_repr:"--scrooge-jvm-options=\"['&lt;str&gt;', '&lt;str&gt;', ...]\"",env_repr:"PANTS_SCROOGE_JVM_OPTIONS",toml_repr:"[scrooge]\njvm_options = [\n    '&lt;str&gt;',\n    '&lt;str&gt;',\n    ...,\n]",default_repr:"[]",children:[(0,o.jsxs)(s.p,{children:["List of JVM options to pass to ",(0,o.jsx)(s.code,{children:"scrooge"})," JVM processes."]}),(0,o.jsxs)(s.p,{children:["Options set here will be added to those set in ",(0,o.jsx)(s.code,{children:"[jvm].global_options"}),". Please check the documentation for the ",(0,o.jsx)(s.code,{children:"jvm"})," subsystem to see what values are accepted here."]})]}),(0,o.jsx)(s.h3,{id:"lockfile",children:(0,o.jsx)(s.code,{children:"lockfile"})}),(0,o.jsxs)(n.A,{cli_repr:"--scrooge-lockfile=&lt;str&gt;",env_repr:"PANTS_SCROOGE_LOCKFILE",toml_repr:"[scrooge]\nlockfile = &lt;str&gt;",default_repr:"&lt;default&gt;",children:[(0,o.jsx)(s.p,{children:"Path to a lockfile used for installing the tool."}),(0,o.jsxs)(s.p,{children:["Set to the string ",(0,o.jsx)(s.code,{children:"&lt;default&gt;"})," to use a lockfile provided by Pants, so long as you have not changed the ",(0,o.jsx)(s.code,{children:"--version"})," option. See ",(0,o.jsx)(s.a,{href:"https://github.com/pantsbuild/pants/blob/release_2.25.1/src/python/pants/backend/codegen/thrift/scrooge/scrooge.default.lockfile.txt",children:"https://github.com/pantsbuild/pants/blob/release_2.25.1/src/python/pants/backend/codegen/thrift/scrooge/scrooge.default.lockfile.txt"})," for the default lockfile contents."]}),(0,o.jsxs)(s.p,{children:["To use a custom lockfile, set this option to a file path relative to the build root, then run ",(0,o.jsx)(s.code,{children:"pants generate-lockfiles --resolve=scrooge"}),"."]})]}),(0,o.jsx)(s.h3,{id:"version",children:(0,o.jsx)(s.code,{children:"version"})}),(0,o.jsx)(n.A,{cli_repr:"--scrooge-version=&lt;str&gt;",env_repr:"PANTS_SCROOGE_VERSION",toml_repr:"[scrooge]\nversion = &lt;str&gt;",default_repr:"21.12.0",children:(0,o.jsxs)(s.p,{children:["Version string for the tool. This is available for substitution in the ",(0,o.jsx)(s.code,{children:"[scrooge].artifacts"})," option by including the string ",(0,o.jsx)(s.code,{children:"{version}"}),"."]})}),(0,o.jsx)(s.h2,{id:"deprecated-options",children:"Deprecated options"}),(0,o.jsx)(s.p,{children:"None"}),(0,o.jsx)(s.h2,{id:"related-subsystems",children:"Related subsystems"}),(0,o.jsx)(s.p,{children:"None"})]})]})}function j(e={}){const{wrapper:s}={...(0,t.R)(),...e.components};return s?(0,o.jsx)(s,{...e,children:(0,o.jsx)(p,{...e})}):p(e)}},87598:(e,s,r)=&gt;{r.d(s,{A:()=&gt;o});const o={options:"options_nrbo"}},142519:(e,s,r)=&gt;{r.d(s,{A:()=&gt;i});var o=r(474848),t=r(276634),n=r(528618);function i({children:e,cli_repr:s,env_repr:r,toml_repr:i,one_of:c,default_repr:l,target_field_name:d,removal_version:a,removal_hint:h}){return(0,o.jsxs)("div",{className:"margin-bottom--lg",children:[(0,o.jsx)("code",{style:{color:"var(--pants-reference-option-repr)"},children:s}),(0,o.jsx)("br",{}),(0,o.jsx)("code",{style:{color:"var(--pants-reference-option-repr)"},children:r}),(0,o.jsx)("br",{}),(0,o.jsx)(t.A,{language:"toml",title:"pants.toml",children:i}),(0,o.jsxs)("div",{style:{paddingLeft:"2em"},children:[(0,o.jsxs)("span",{children:[c&amp;&amp;(0,o.jsxs)("span",{children:["one of:"," ",(0,o.jsx)("code",{style:{color:"var(--ifm-color-success)"},children:c}),(0,o.jsx)("br",{})]}),"default:"," ",(0,o.jsx)("span",{style:{color:"var(--ifm-color-success)"},children:(l||"").includes("\n")?(0,o.jsx)("pre",{className:"padding--sm",children:l}):(0,o.jsx)("code",{children:l})})]}),(0,o.jsx)("br",{}),a&amp;&amp;(0,o.jsxs)("span",{style:{color:"var(--ifm-color-danger-darkest)"},children:["Deprecated, will be removed in version: ",a,".",(0,o.jsx)("br",{}),h,(0,o.jsx)("br",{})]}),e,d&amp;&amp;(0,o.jsxs)("span",{children:["Can be overriden by field",(0,o.jsx)("code",{children:d})," on"," ",(0,o.jsx)(n.A,{to:"../targets/local_environment",children:(0,o.jsx)("code",{children:"local_environment"})}),","," ",(0,o.jsx)(n.A,{to:"../targets/docker_environment",children:(0,o.jsx)("code",{children:"docker_environment"})}),", or"," ",(0,o.jsx)(n.A,{to:"../targets/remote_environment",children:(0,o.jsx)("code",{children:"remote_environment"})}),"targets."]})]})]})}}}]);</pre></body></html>