{"id":16572887,"url":"https://github.com/coatless/formateq","last_synced_at":"2026-05-28T21:31:21.680Z","repository":{"id":89518717,"uuid":"82611662","full_name":"coatless/formatEQ","owner":"coatless","description":"Same formatting rules afforded by formatR with the exception that `\u003c-` is transformed to `=`.","archived":false,"fork":false,"pushed_at":"2017-02-21T17:50:29.000Z","size":7,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-12-13T09:54:45.917Z","etag":null,"topics":["r"],"latest_commit_sha":null,"homepage":null,"language":"R","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/coatless.png","metadata":{"files":{"readme":"README.Rmd","changelog":"NEWS.md","contributing":null,"funding":null,"license":null,"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":"2017-02-20T23:02:00.000Z","updated_at":"2017-02-21T05:55:25.000Z","dependencies_parsed_at":null,"dependency_job_id":"ee7f1af8-bd1b-45c5-ba53-fdc84177a3a4","html_url":"https://github.com/coatless/formatEQ","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/coatless/formatEQ","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coatless%2FformatEQ","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coatless%2FformatEQ/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coatless%2FformatEQ/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coatless%2FformatEQ/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/coatless","download_url":"https://codeload.github.com/coatless/formatEQ/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/coatless%2FformatEQ/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33627934,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-28T02:00:06.440Z","response_time":99,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":["r"],"created_at":"2024-10-11T21:28:49.512Z","updated_at":"2026-05-28T21:31:21.664Z","avatar_url":"https://github.com/coatless.png","language":"R","funding_links":[],"categories":[],"sub_categories":[],"readme":"---\noutput: github_document\n---\n\n```{r, echo = FALSE}\nknitr::opts_chunk$set(\n  collapse = TRUE,\n  comment = \"#\u003e\",\n  fig.path = \"README-\"\n)\n```\n\n# `formatEQ`  correcting assignment styling in [`formatR`](https://cran.r-project.org/package=formatR)\n\nThe objective of this package is to write a short patch to Yihui Xie's \n[`formatR`](https://cran.r-project.org/package=formatR) package that inverts the\ndefault behavior of the assignment operator replacement formatting rule so that \nwhenever `\u003c-` is present it is replaced with `=`.\n\n## Download Instructions\n\nPresently, the package is only available on GitHub. It may eventually matriculate\nto CRAN if there is interest.\n\n```r\n# install.packages(\"devtools\")\ndevtools::install_github(\"coatless/formatEQ\")\n```\n\n## How was this accomplished? \n\nTo accomplish this, an [override function trick](https://stat.ethz.ch/pipermail/r-help/2008-August/171217.html)\ndeveloped by [Henrik Bengtsson](https://github.com/HenrikBengtsson) is employed.\nThe trick allows for a very minimal change to occur to the \n[`replacement_assignment()`](https://github.com/yihui/formatR/blob/022da8c1be2c04c8374d19907c41bacd5d0ecfcc/R/utils.R#L1-L18)\nfunction within [`formatR`](https://cran.r-project.org/package=formatR). Thus,\nthere is no need to copy _all_ of the package, but only the necessary components.\nOn package load, the function trick is then applied. Thus, if you were to\nindependently load `formatR`, the content would remain exactly the same.\n\n## Why not submit a patch?\n\nUnfortunately, this is more of a style guideline change and, thus, does _not_\nwarrant a patch. Furthermore, the API for the `tidy_source` function is already\nquite established and adding an option to seeminly invert the authors intended\nfunctionality would likely yield numerous breakages. So, the safer course of\naction is to provide a way for regenades of assignment to express themselves since:\n\n\u003e No matter how hard you try, you can't stop us now\n\u003e\n\u003e We're the renegades of this time and age\n\u003e\n\u003e This is the time and age of renegades\n\u003e\n\u003e --- [Rage Against the Machine - Renegades of Funk](https://www.youtube.com/watch?v=K626gMvu2ds)\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoatless%2Fformateq","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcoatless%2Fformateq","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcoatless%2Fformateq/lists"}