Short answer:
You absolutely shouldn't try to hide anything that could be relevant to the position that you're applying for, as most hiring managers are looking for honest candidates who are showing willingness for career growth over the "perfect" candidate.
Longer answer:
You have 2 options.
- You put those jobs on your resume. You will need to be prepared to explain why you went through so many jobs in such a short time, and you absolutely cannot portray any of those companies in a negative light, as then the company that you're applying for will probably also think that you won't show much loyalty to them either. Try to be as positive about those jobs as possible (such as what you learned at those jobs and how that knowledge can apply to future jobs), and your future employer might also think that you'll be positive about your future job as well.
- You can decide to leave the jobs off the resume. You will then need to be prepared to explain what you did in the time gap that you left on your resume, likely with a similar answer to the question in Option 1. You may also need to explain why you didn't feel like you wanted to place those jobs on your resume.
I'd strongly recommend option 1 if the jobs you previously worked at would help give you credibility when applying to your potential job, and option 2 if your potential job doesn't have much to do with your previous jobs. You definitely don't want to be seen as trying to hide your past; on the contrary, you should own up to it and be able to learn from it.
Lastly, responding to what you said in your comment (and the fact that you had 5 jobs in 4 years), every company you work at, large and small, will have some sort of mess to deal with. As part of a software development team, you will run into developers that have different (and possibly much worse) coding habits that you do. Furthermore, every for-profit company (and many non-profit companies) out there is solely interested in making money, and thus will try to bill as many hours as they can. My point is that it sounds like you may need some sort of a change in how you work, possibly from a time management perspective, such as learning to produce the best work you can on the time budget you're allocated, or a change in attitude toward work overall, especially in learning what makes a company good to work for.