Posts

Showing posts with the label Software Development

Change GitLab Account on your local Git configuration on Windows

Image
The amazing Gitlab Recently, I created a new GitLab account and wanted to switch to it on my local machine. When pushing to a remote repository, the credentials from the first account are still being used. Typically, you need to remove the old user credentials and then authorize the new account. Here's how to do that on Windows. 1. Remove Stored Credentials If you've been using HTTPS for authentication, your credentials might be stored in the Windows Credential Manager. Removing these old credentials is the first step to ensure that your local machine asks for the new ones. Using Windows Credential Manager Open Credential Manager: Press Win + S , type "Credential Manager" and open it. Find GitLab Credentials: Navigate to the "Windows Credentials" tab and look for entries related to GitLab, which are likely named something like git:https://gitlab.com . Remove these entries to delete the stored credentials. Remove these credentials 2. Update Git Use...

Firebase and JQuery Tech Stack - Simplest and most Scalable way of developing a website

Image
Firebase jQuery Bootstrap stack A lot of companies and indie developers in the real world develop websites using so many tech stacks that it is such a waste of time, money, and resources. It’s economically not wise, either they don't know or they are just deliberately doing so to make the company they work for spend tons of money. Certainly, there’s a better approach to doing websites, which should be a cloud base. This is not a secret, you can develop a large-scale application with just less tech stack that even a beginner does not need to learn so many tech stacks. The tech stack I recommend is Firebase, JQuery, and Bootstrap. In the traditional app, these are the workflow of setting up the tech stack to make their website run: Lease a server from some hosting company Install the OS for the database Setting up the database of choice: MySQL, Postgre, Oracle, Mongo, whatever Install the OS for the backend / Rest API Setting up the web server for the backend API Developing some back...

Event Driven Microservice Spring Boot with Apache Kafka

Image
Apache kafka logo Apache Kafka in simple terms is a collection of logs of events when some data in a database changes, divided into topics. This is why it is called event driven architecture, when some service saves data in a database, you use Kafka to produce an event so that other services (wherever it is located) can listen on that event and do some computation whatever they want based on the event that is firing. Kafka is usually used for microservices architecture, so instead of reading data from a database, each microservices communicate with Kafka events, which we call produce and consume. Produce is Kafka term to emit a message to a specific topic, meanwhile consume is to listen to an event that contains data that is produced by some other microservices. Monolithic application Microservice architecture application What is Event-driven Microservices Microservice design is a way to develop an application and split it into small independently deployable services, each microservice...

How To Use Package Manager In C++ Windows

Image
C++ logo frow Wikipedia The thing I like about coding in C and C++ is the low level stuff, and the simplicity. But this simplicity is also one of the things that makes C doesn’t seem to fit for rapid development applications. Although sure it depends on how experienced the programmer is, for someone who has been doing C/C++ for a while, it’s not gonna be much of a problem.  But for beginner C and C++ like me, coming from higher level programming languages and tools, even small things like how to use a library for example the library that we are gonna use is cURL, are already big steps that it is already hard to handle quickly. If you are someone like me, a C/C++ beginner and want to use this very useful Curl library, on Windows, here’s how you can use Curl or any other library.  In Linux based OS maybe it could be much more straightforward, because cURL is usually already included. Now we can easily  use any libraries, thanks to VCPKG: a C++ package manager for Windows, a...

How To Create C/C++ Code In Visual Studio Code

Image
 I like Visual studio code, it’s cross-platformed, and very fast IDE(or for some people they just call it a text editor). But this text editor is very smart and supports many features, well actually you can just create your own extensions if you think that your programming language or tool is not available in the extension market. In this tutorial I am using Windows, to develop C/C++ code, firstable you need to already have C/C++ build tools, which you can install through Visual studio installer. But if you prefer using MinGW or Cygwin, it’s up to you, but i am not familiar with that. 1. Assuming you don’t have C++ build tools on your windows machine, then first you need to Download Build Tools for Visual Studio 2019 here: https://visualstudio.microsoft.com/downloads/#build-tools-for-visual-studio-2019 2. Open Visual studio installer 2019, select Desktop development with C++, and install them. 3. All those above steps are just one time process, you're not gonna repeat that each tim...

Start Using Docker Great Video Tutorial For Beginners

Image
docker logo It’s not gonna be a post about a testimonial or using Docker as an expert docker user, contrary i don’t even know how to use it, i am just starting to use it. So there will be no useful tips or tricks provided on this post about docker. It's been a while since i've first heard about Docker, i tried to use it several times but didn't get any reason on what is docker can be used for, then i uninstalled it, and reinstalled it many many times, still not getting any idea how useful docker is. Then I watched a really good presentation about Docker, this is the most basic Docker that made me amaze how cool docker is. Here’s the link of the video. I am still kind of unsure how to properly use docker though, because my software development career is usually not involving something like a mission critical system that we need to care about hardware level, and also the language and the platform i am mostly used like Java is already handling the cross platform part. Docker h...

How To Start PHP Storm Plugin Development For The First Time

Image
Phpstorm version 2020.1 I was impressed by how smart Intellij IDEA and other jetbrains IDE products can be. If you use a framework, library or tool that the IDE doesn’t support, they also provide you with an API to develop your own plugin to support that framework or tool.  Problem is, it is not as easy as flipping your hand. In fact it’s pretty much night mare, because the lack of documentation and also plugin development is usually a very complex thing, that sometimes your framework that you want to develop the plugin is radically different from the simple example they provide, so you need to figure it out yourself. Recently I learned to develop a PHP framework plugin for PhpStorm, the framework is called Codeigniter. The framework is pretty much popular in the PHP world although kind of old and irrelevant to modern web application development using PHP compared to Symfony or Laravel. But I decided to keep going and with spirits in mind that if anyone can then i’ll learn in the e...

Must-have Windows appplication for software developer fresh OS install

Image
Must-have Windows appplication for software developer fresh OS install 1. Gimp Gimp is an open source lightweight very capable image editor, sometimes we need to just resize, cropping, or layering an image, Gimp can do many things to alter images. It is a free and fast application, also the learning curve is easier than let’s say Adobe products with many hidden little buttons we don’t even want to know about it. 2. Git Git is the most popular version control, every software developer using Git nowadays, its command line is simple and we can use it to clone as many cool open source projects as we want. I mean not just cloning, you can use git for your daily routine developing your app in your  professional tech company. 3. Google chrome If you are using windows there’s already have two ugly web browser by default (explorer and edge), such a waste of disk space, if i could get rid of it i would definitely uninstall it from the beginning of OS installation, it’s an F ...

Non Technical Tips For Programmer If You Want A Good Life

Image
Programmer Photo by Kelly Sikkema on Unsplash Programming is not an exclusive job that only you or some small percentage of people can do this job. Programmers can be found everywhere around the world because to learn any programming is easy nowadays. That's why it's gonna be difficult to make decent money as a programmer or software developer. It is also not a job where you can just sit and relax because you need to focus on solving the tasks the project manager given to you. Sometimes it can be really stressful working as a programmer, different bugs, security issues, reading other team codes that's unreadable, tasks that can not be done in minutes, sometimes it can take hours if not days for just solving a single task. It is important to do this below tips i given to you to make a balance between your career and your personal life. I've been doing programming quite awhile, so maybe I can share some tips, it's not a technical tips. 1. Sleep and wake up...

Some Helpful Tips For Beginner Web Programmer Front End And Back End

Image
Web Programmer - Image by TeeFarm from Pixabay I am not a pro web programmer, but I've been in this industry for about 5 years now, I think it's quite enough experiences to have some lesson learned along my career. I do both for front end and back end development, so these tips are for you if you are just starting your career on web programming on those areas. 1. Always finish the task, never postpone In any situation, if you postpone something it's going to be really hard to start, so you will waste a lot of time if you are not trying to finish the task right now. Writing codes can take time, even some task that we thought it could only took several minutes, but along the way while you are trying to solve these problems, it turns out to be there are a lot of complicated logic that one depends on another. So the problems can only be fixed if you fix the other first, that could end up in a long chain of codes. 2. Focus on the output, not on the codes Whatever th...

Devdocs An Offline Programming Language Documentation

Image
Devdocs logo devdocs.io As a programmer i am very often forget what some sort of commands or syntax to do some even basic software problems, documentation can be really useful for us to search for what we are trying to solve. Usually all programming languages already has their documentation on their official website, it is up to you to search the information you need either from the official or on Devdocs. The thing about Devdocs is, it has cool web interface, some clear explanation and examples on how to use the language syntax, and there is offline features, so you can still read it even if you don't have internet connection. Usually Google is the only best place to search for everything about all problems we faced, but if you are a programmer advanced enough, maybe you don't need Google at all, you already familiar with all the syntax in the world and just coding on your favorite IDE and never bother to open web browser. Devdocs is cool program, you can get refere...

How To Create Phpinfo to List What PHP Configuration Have

Image
PHP is programming language mainly used by Web developer to develop their web application. It is actually one of my first programming language that i learnt in the past. It is a simple easy to start programming language to do a web development. Capable of doing database transaction, JSON parsing, file operation, etc. Sometimes when you develop your web application and in the middle of your activity you find a problem with your codes, and you need to now detail about your PHP configuration for example, whether MySQL module is enabled, XML parser enable, etc. You can check all that information by using a single PHP function. You can use phpinfo() function, to enumerate all your PHP configuration have. You simply only need to create a file, let's give it a name ' phpinfo.php ' and the content of the file is this one single line PHP code: <?php phpinfo(); ?> Now open the browser and locate to that file, for example if you are developing your app on your local com...

Create A Maven Java Project On Eclipse IDE

Image
Eclipse is one of the popular Java IDE out there, many people still considered Eclipse as their main integrated development tools for developing Java based project. It is because Eclipse has capability of syntax highlighting, code completion, running, debugging and compiling Java project. In this tutorial, we are gonna discuss how to create a Java project using Maven build tool. Maven is in my opinion the best build tool for Java project, i couldn't explain in detail in this post, because there is gonna be a long list of good and bad about Maven, so it will be discuss on the upcoming post. To create a new maven project: 1. Click File on top menu, and then New and then Project 2. On new Project wizard, choose Maven Project , and then Next 3. On Project location, just click Next 4. On Wizard select archetype, also click Next 5. For testing purpose, you can just fill the group and artifact id with "test", but you can make it whatever as you want 6. ...

JavaFX Email Validation using JFoenix TextField

Image
Javafx email validation box I encourage you to use Jfoenix material UI for developing JavaFX GUI, I've been using it for a while and been really happy, it's cool library, more people should use it so this cool project will continue to alive, this project been so slow in progress lately. You can use this library, put in your pom.xml dependencies tag. <dependency> <groupId>com.jfoenix</groupId> <artifactId>jfoenix</artifactId> <version>8.0.1</version> </dependency> Use the right version, that version above is for Java 8 and below, if you are using Java 9 and above use this version instead: <dependency> <groupId>com.jfoenix</groupId> <artifactId>jfoenix</artifactId> <version>9.0.9</version> </dependency> What we're gonna do is using JFoenix JFXTextField to make a box that if the user is input the wrong email format, if it's not a valid emai...

JavaFX Dialog Material Design

Image
Jfoenix is a library to build JavaFX application using Material design principal. One of my favorite library and always use it whenever i program desktop application. You can get the library from this official website www.jfoenix.com , read the documentation for further use, or just put this to your Maven pom.xml : <dependency>     <groupId>com.jfoenix</groupId>     <artifactId>jfoenix</artifactId>     <version>8.0.9</version> </dependency> And this is about showing dialog in JavaFX, it has modern look with shadowing and animation when it showing and closing. This is full example on how to create a dialog with Jfoenix JfxDialog: import com.jfoenix.controls.JFXButton; import com.jfoenix.controls.JFXDialog; import com.jfoenix.controls.JFXDialogLayout; import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.control.Label; import javafx.scene.layout.BorderPane; import j...

JavaFX Alert Dialog Example With Pictures

Image
JavaFX has 5 different alert types, each have their own different icon button, and functionality. You can specify an alert based on what your application need. For example if you want to have and alert to indicate user input error, you can then use an alert then specifying the alert type with  Alert.AlertType.ERROR. And  these are 5 different types of JavaFX alert dialog: 1. Error Alert - usually to indicate an error Alert alert = new Alert(Alert.AlertType.ERROR); alert.setContentText("Alert Message"); alert.show(); 2. Info Alert - usually use for information Alert alert = new Alert(Alert.AlertType.INFORMATION); alert.setContentText("Alert Message"); alert.show(); 3. Confirmation Alert Alert alert = new Alert(Alert.AlertType.CONFIRMATION); alert.setContentText("Alert Message"); alert.show(); 4. Warning Alert Alert alert = new Alert(Alert.AlertType.WARNING); alert.setContentText("Alert Message"); alert.show(); 5. Empty ...

JavaFX Combo Box with Search Autocomplete

Image
JavaFX is a java framework for building cross-platform desktop application under the Java Platform, i have been doing JavaFX programming for the last couples of months and been feel really happy. It's good practice to build a desktop application UI, instead of web-based UI, i mean, and the thing that it's under Java, it has lot of supporting tools and libraries. Yeah Java has been sucks on the UI, even me as I've been doing web for years, i feel really frustrated doing UI programming for the first time in Java. It is hard to find for example a library to support a combo box with search functionality, you can find it a lot's of lots library in Javascript, but Java, i'd say none, i should implement it myself, and it's been really difficult as i don't think i have enough experiences in JavaFX. So here's a simple implementation of JavaFX combo box with search autocomplete. Create a class name it AutoCompleteBox.java: import javafx.application.Platform...

JavaFX Login Example Codes

Image
This is example of a login form created using JavaFX import javafx.application.Application; import javafx.geometry.Insets; import javafx.scene.Scene; import javafx.scene.control.Button; import javafx.scene.control.Label; import javafx.scene.control.PasswordField; import javafx.scene.control.TextField; import javafx.scene.layout.StackPane; import javafx.scene.layout.VBox; import javafx.stage.Stage; public class App extends Application { private StackPane root = new StackPane(); private Stage stage; @Override public void init() { Button button = new Button("OPEN"); VBox vBox = new VBox(); vBox.setSpacing(8); vBox.setPadding(new Insets(10,10,10,10)); vBox.getChildren().addAll( new Label("Your Username"), new TextField(), new Label("Your Password"), new PasswordField(), new Button("LOGIN")); root.getCh...

JavaFX Load Local HTML File Using WebView

Image
JavaFX is platform to create GUI for desktop application in Java, it has more modern and performance than any other framework for desktop application development. It also support template using FXML and styling using CSS. You can load an HTML file into JavaFX application using WebView, either it's available online, internet connection required or a local HTML resource, support CSS and Javascript. To load an HTML we can use WebView for example: 1. First create an html and put it on /src/main/resources/helloWorld.html <html lang="en"> <head><title>Hello World</title></head> <body><h1>Hello world!</h1></body> </html> 2. Now for just demo, create a class name HelloWorldApplication.java that contains main method. import javafx.application.Application; import javafx.scene.Scene; import javafx.scene.web.WebEngine; import javafx.scene.web.WebView; import javafx.stage.Stage; public class HelloWo...

Service In Spring Boot For Beginners

Image
Service in spring boot is component where you usually place your business logic of your application. So service will be the class where mostly you will write Java code. Business logic can be anything for example, when user update profile, buying items, checkout, etc. So here's an example of simple service in spring for user registration, login, update, and remove. @Service public class UserService{ @UserRepository private UserRepository userRepository; public User registration(User newUser){ return userRepository.save(newUser); } public User login(UserDto user){ return userRepository.findByUsername(user.getUsername()); } public User update(Long id, User newUser){ User user = userRepository.findById(id).orElse(new User); user.setUsername(newUser.getUsername()); user.setName(newUser.getName()); userRepository.save(user); return user; } public void remove(Long id){ userRepository.deleteById(id); } } To make a class as a service, you add a @Service annotat...

Popular posts from this blog

How to Install Microsoft Office on Your PC: A Step-by-Step Guide

Coding On Your Android Phone Using Termux

The Hidden Disk Hogs on Windows Developers Keep Ignoring (And How to Move Them to D:)