{"id":15764481,"url":"https://github.com/lewisjkl/header","last_synced_at":"2025-03-13T21:32:47.097Z","repository":{"id":62133709,"uuid":"540543717","full_name":"lewisjkl/header","owner":"lewisjkl","description":"Header automation and linting :tada:","archived":false,"fork":false,"pushed_at":"2024-12-25T02:44:04.000Z","size":30,"stargazers_count":7,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-13T09:43:44.699Z","etag":null,"topics":["mill-plugin"],"latest_commit_sha":null,"homepage":"","language":"Scala","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lewisjkl.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":"2022-09-23T17:15:30.000Z","updated_at":"2024-12-25T02:44:08.000Z","dependencies_parsed_at":"2025-01-24T23:24:00.336Z","dependency_job_id":null,"html_url":"https://github.com/lewisjkl/header","commit_stats":{"total_commits":13,"total_committers":2,"mean_commits":6.5,"dds":0.07692307692307687,"last_synced_commit":"65fc8cac034afb2bdda0cee11f233a9ec5f5676c"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lewisjkl%2Fheader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lewisjkl%2Fheader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lewisjkl%2Fheader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lewisjkl%2Fheader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lewisjkl","download_url":"https://codeload.github.com/lewisjkl/header/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":243485914,"owners_count":20298421,"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":["mill-plugin"],"created_at":"2024-10-04T12:03:52.739Z","updated_at":"2025-03-13T21:32:47.088Z","avatar_url":"https://github.com/lewisjkl.png","language":"Scala","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Header\n\n_Utilities for checking and updating headers in files._\n\nA big thanks to [sbt-header](https://github.com/sbt/sbt-header) which this project is based on.\n\n## Mill - Basic Usage\n\n```console\n\u003e mill __.headerCheck\n\u003e mill __.headerCreate\n```\n\nIn `build.sc` file:\n\n```scala\nimport $ivy.`com.lewisjkl::header-mill-plugin::0.0.4`\nimport header._\n```\n\n\u003c!--\n// Need this so mdoc thinks we are inside of a proper mill context\n// but put this in a comment so it won't show up on GitHub\n```scala mdoc:invisible\nimplicit def ctx: mill.define.Ctx = ???\n```\n--\u003e\n\n#### Apache 2\n\n```scala mdoc:nest\nimport header._\n\nobject core extends HeaderModule {\n  override def license: HeaderLicense = HeaderLicense.Apache2(\"2023\", \"lewisjkl\")\n}\n```\n\n#### MIT\n\n```scala mdoc:nest\nimport header._\n\nobject core extends HeaderModule {\n  override def license: HeaderLicense = HeaderLicense.MIT(\"2023\", \"lewisjkl\")\n}\n```\n\n#### Custom\n\n```scala mdoc:nest\nimport header._\n\nobject core extends HeaderModule {\n  override def license: HeaderLicense = HeaderLicense.Custom(\n  \"\"\"|The contents of this file is free and unencumbered software released into the\n     |public domain. For more information, please refer to \u003chttp://unlicense.org/\u003e\"\"\".stripMargin\n  )\n}\n```\n\n## Mill Customization\n\n```scala mdoc:nest\nimport header._\n\nobject core extends HeaderModule {\n  override def license: HeaderLicense = HeaderLicense.Apache2(\"2023\", \"lewisjkl\")\n\n  // defaults to List(\"scala\")\n  override def includeFileExtensions: List[String] = List(\"scala\", \"java\")\n\n  // if you want more control, you can use the following instead of `includeFileExtensions`\n  // This shows the default implementation, but you can make it whatever you would like.\n  override def skipFilePredicate: os.Path =\u003e Boolean = path =\u003e {\n    os.isFile(path) \u0026\u0026 !includeFileExtensions.exists(ext =\u003e\n      path.segments.toList.last.endsWith(s\".$ext\")\n    )\n  }\n\n  // defaults to this.millSourcePath, change this to change where the header checking/creation starts\n  // looking for files\n  override def headerRootPath: os.Path = millSourcePath\n}\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flewisjkl%2Fheader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flewisjkl%2Fheader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flewisjkl%2Fheader/lists"}