rohitdhas / shittier Goto Github PK
View Code? Open in Web Editor NEWShittier is an unconventional code formatting tool
Home Page: https://www.npmjs.com/package/shittier
License: MIT License
Shittier is an unconventional code formatting tool
Home Page: https://www.npmjs.com/package/shittier
License: MIT License
"This plugin truly made my codebase shittier" - Developer at X
"My code is a pile of shit now! So effective" - Developer at Y
"I can't believe how shitty shittier is" - Developer at Z
I believe testimonials would make the plugin much more credible.
I'm interested in contributing to creating shitty code and think Python would be a better language due to the multitude of natural language processing libraries out there in Python such as NLTK. This should make it easier to support multitudes of programming languages.
I would love to share my shittier config with other people on my team in this way
Hey there π
I love silly projects like this, so thanks for creating this π π
I have packaged it for NixOS, so that it will be possible to install it using the Nix package manager.
Since you haven't yet created a release on GitHub yet, I had to package it as unstable. Seeing that it got released on npm as version 0.1.1, could you also create a release on GitHub?
For more information on how to create releases on GitHub, you can refer to the official GitHub documentation.
If that is too much work, could you just tag releases that you push to npm with git tag
and then push them to the repository with git push --tags
π
Thanks in advance!
This is pretty shitty code in my opinion. Dow how can I make it even shittier?
Indentation, a bunch of new lines and even syntax highlighting is so out of style for modern software development.
Instead, I suggest a formatter that would convert indented code into prose: without newlines, separated only by semicolons, so it is readable as normal human text.
We've been using this notation for centuries! Imagine what how a much space would be needed if you wanted to indented a novel, for example War and Peace?
as title :D
Readability of a code remains intact. Better to randomly place the comment around and convert some condition into ternary, rename some variables into random shit and any idea you came up with.
i suggest using chatgpt for it
When there is a function call, replace it with the real function code. Moreover, remove the function code if there is no place to use it. Everything in a single main function should be pretty impressive
The worst code has bizarre line-space grouping so you think you see blocks of logic where there are none. The best place for this is anything in a book or sample, where suckers who are learning donβt know any better.
It should also rename things, but subtly. So, remove any verbs so the caller can't tell if the call might mutate state or have side-effects.
Also, where you have e.g. a count of cats, call that variable just cats
so it appears as if it could reasonably contain the actual iterable of cats, but also contain the count of cats such that you're bound to lose in an argument with the author.
This could be part of a new tool call refuctor.
I don't have any prior experience with TS, but I'm eager to learn how to set up a plugin for a particular programming language. Like this https://github.com/prettier/plugin-php
I am grateful for your hard work.
Please add options to rename variables. Either :
Please add an option to insert random copious amounts of line breaks.
Please add TS support so that we can make the source of Shittier shittier, which isn't currently shitty enough for my eyes.
I try to run this on my code and nothing changes please help
is there any way to do it in java or python?
thankyou for your attention
Is it even possible?
Because then this would be valid after all.
Howdy,
I am planning to use this in my super important business job, and would like it as a pre-commit hook.
Sadly I have no dev experience, but I'm more than happy to write the docs for this!
input
<!doctype html>
<meta charset="utf-8">
<title>SpOnGeBoB cAsE iS tHe OnLy WaY tO lIvE</title>
output
<!DoCtYpE hTmL>
<mEtA
ChArSeT=utf-8
><tItLe
>SpOnGeBoB cAsE iS tHe OnLy WaY tO lIvE
</TiTlE>
Because we are using bad practices anyway, when you have two variables with the same name, but different capitalization, there is a chance of the variables merging.
input:
const message = "hello there"
const Message = "hello there"
output:
const MESSAGE = "hello there"
const MESSAGE = "hello there"
The chance of this happening is slim, depending on the length of the variable:
Code:
var a = 5;
console.log(a.toString());
Result:
var A = 5 ;
console .log (A .function toString() { [native code] } ( ) ) ;
Error:
console .log (A .function toString() { [native code] } ( ) ) ;
^^^^^^^^
SyntaxError: missing ) after argument list
In JavaScript, functions are hoisted, which means that even if a function is declared at the bottom of the file, it can still be accessed at the top. This hoisting behavior is causing an issue in Shittier, specifically when we search for function declarations to modify their case and make corresponding modifications wherever the function is called throughout the code.
The problem arises due to hoisting, as users can call the function even before it's defined explicitly in the code. As a result, the case modification process fails, and it breaks the code execution.
Expected Behavior:
The case modification process in Shittier should handle hoisting correctly, ensuring that the function's case is modified consistently throughout the codebase, regardless of whether the function is called before or after its declaration.
Steps to Reproduce:
Observed Behavior:
The function's case is not modified when it is called before its explicit declaration, leading to unexpected behavior and code execution errors.
Expected Behavior:
The function's case should be modified consistently throughout the codebase, regardless of the function's hoisting behavior.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
π Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. πππ
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google β€οΈ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.