Nerdschoolbergen/code-smells - GitHub

Skip to content Dismiss alert {{ message }} / code-smells Public
  • Notifications You must be signed in to change notification settings
  • Fork 65
  • Star 33
  • Code
  • Issues 2
  • Pull requests 1
  • Actions
  • Projects
  • Security
  • Insights
Additional navigation options  masterBranchesTagsGo to fileCode

Folders and files

NameNameLast commit messageLast commit date

Latest commit

 

History

37 Commits
.devcontainer.devcontainer  
.github.github  
.vscode.vscode  
srcsrc  
.gitignore.gitignore  
README.mdREADME.md  
exercise.mdexercise.md  
pom.xmlpom.xml  
smells.mdsmells.md  
View all files

Repository files navigation

  • README
Refactoring and code smells

Somewhere along the way code goes from good to bad. It's usually a combination of many small factors that when allowed to take hold in your project, makes it hard to work with and downright frustrating. Your code starts to smell... bad...

Open presentation slides

Focus of this lesson

In this workshop you'll work together in a team. You'll get to know some of the most common code smells and how to fix them. After this workshop you'll know the basics of clean code and how to refactor your smelly code with test coverage.

What you need

  • IntelliJ Community Edition: IntelliJ Community Edition
  • Java dev kit: Java SE Development Kit

How to get started

  • Start by cloning this repository into a folder on your computer. If you've never used git before, you can alternatively use the the "Download ZIP" button to the right.
  • Although you have this README.md file on your computer it's easier to read it on GitHub, so we recommend you keep this page open with the exercise tasks.

Exercise

Go to Exercise - Fix the smelly code to get started.

Helpful resources

  • IntelliJ User interface
  • IntelliJ interactive training course
  • IntelliJ for Eclipse users
  • IntelliJ testing

See smells.md for a shortlist of code smells and how to fix them.

Symbols and notation used in exercises

Icons with special meaning

  • ✏️ - A task you should do
  • 📖 - A section of text to read (no tasks, just information).
  • 💡 - Additional information.
  • ❗ - Something important.
  • ❓ - Open-ended question for the reader ("What do you think would happen if...")
  • 💩 - Bad practice (don't-do-this)
  • ⭐ - A bonus task (not required)

Keyboard keys

Will look like this:

CTRL + ALT + C

Diff blocks

Emphasizes how lines of text should change.

- this text was removed + and replaced with this text

About

Somewhere along the way code goes from good to bad. It's usually a combination of many small factors that when allowed to take hold in your project, makes it hard to work with and downright frustrating. Your code starts to smell... bad...

Resources

Readme

Uh oh!

There was an error while loading. Please reload this page.

Activity Custom properties

Stars

33 stars

Watchers

5 watching

Forks

65 forks Report repository

Releases

No releases published

Packages

Uh oh!

There was an error while loading. Please reload this page.

Uh oh!

There was an error while loading. Please reload this page.

Contributors

Uh oh!

There was an error while loading. Please reload this page.

Languages

  • Java 100.0%
You can’t perform that action at this time.

Tag » Code Smells Examples Java