Understanding Java ClassPath

 Java class path```java -cp <path_to_jar>:<path_to_current_class> Main.class -> for linuxjava -cp <path_to_jar>:<path_to_current_class> Main.class -> for windows```java -cp ..:. Main.. indicates the previous directory; | : separator for linux or windows. indicates the current working directory loading classes from jarto create jarjar cvf <jar_file_name.jar>...

How to see logs with out Esc and other gibberish stuff in logs ?

 So when you are trying to read logs, sometimes they look like this, using vim is okay at-least some readability, but less will show awful results. ESC[34m2023-04-15 04:33:57ESC[0m ESC[33m  TRACEESC[0m [ESC[36mApplicationESC[0m] ESC[37mpid: 562425ESC[0mESC[34m2023-04-15 04:33:57ESC[0m ESC[35m  DEBUGESC[0m [ESC[36mApplicationESC[0m] ESC[37minteractive: falseESC[0mESC[34m2023-04-15...

VIM: Binding a shortcut

 All this time, I do not know how to create my own VIM Bindings. And yes, trying yourself is the only way you learn anything.I want to explain what I have learnt on creating a vim shortcut, so you might get a good headstart.The command I am going to explain is as belowmap <C-b> :w\|!ruby spec/example_spec.rb <cr>somap: is like you are mapping <custome_key> <series of actions><C-b>:...

Javascript: call vs bind vs apply

 Hello Everyone, I came across a snippet where code have .call() method.Thought its been a while since I went through their understanding, via this article I am explaining with examples what call, bind and apply does in javascript.Please read comments for understanding.Hope it helps.var obj = { name: "Raja", sayHello: function(args) { console.log(`Hello ${this.name}, How are...

GoLang: Quick gist on Difference between Marshal, Unmarshal, Encoder and Decoder

Summary: Marshal, Unmarshal and Encode, Decode /* From extension vscode.github */ /*--------------------------------------------------------------------------------------------- * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for license information. *--------------------------------------------------------------------------------------------*/ .vscode-dark...

GoLang: How to render a web template using Gin framework and render data from map ?

 I have struggled lot of time, to break this into working modal. So below code, is working example where you can have your data in a slice of URLs and render that data using Go Templates. I am giving a skeleton HTML template, not adding any thing extra. I believe the code itself is self explanatory, if any questions, please dont hesitate to ask.main.gopackage mainimport ( "log" ...