Skip to content

Instantly share code, notes, and snippets.

View KylianVermeulen's full-sized avatar
🏆
On vacation

Kylian Vermeulen KylianVermeulen

🏆
On vacation
View GitHub Profile
@KylianVermeulen
KylianVermeulen / SpelExpressionParser.java
Created December 6, 2021 10:18
Spel Expression Parser
private static final SpelExpressionParser PARSER = new SpelExpressionParser();
String[] fields = {"userLanguage", "query.queryParameters"};
List<Object> objects = Stream.of(fields).map(field -> PARSER.parseExpression(field).getValue(searchModel)).filter(Objects::nonNull).collect(Collectors.toList());
logger.debug("Not Null: " + objects);
@KylianVermeulen
KylianVermeulen / repo-reset.md
Created July 1, 2017 01:03 — forked from heiswayi/repo-reset.md
GitHub - Delete commits history with git commands

First Method

Deleting the .git folder may cause problems in our git repository. If we want to delete all of our commits history, but keep the code in its current state, try this:

# Check out to a temporary branch:
git checkout --orphan TEMP_BRANCH

# Add all the files:
git add -A