Method to Scan a Copy Files from a Folder Another Folder with a CSV File

Here is the code to provide the sorting method of getting the files to be copied from a folder to another folder based on the required list of names #!/bin/bash CSV_FILE=”{CSV_File}.csv” SOURCE_DIR=”{Source_location}P” DEST_DIR=”{destination_location}” # Create destination directory if not exists mkdir -p “$DEST_DIR” # normalize: trim, remove CR, remove all spaces, lowercase normalize() {  … Continue reading Method to Scan a Copy Files from a Folder Another Folder with a CSV File

Sh Code to Convert Files from JPG to WEPB in bulk from a folder

Firstly Need to Install webp Extension on the linux or operating system #!/bin/bash # Usage: ./jpg-to-webp-folder.sh /path/to/input /path/to/output INPUT_DIR=”{location}” OUTPUT_DIR=”{location}” # Check inputs if [ -z “$INPUT_DIR” ] || [ -z “$OUTPUT_DIR” ]; then     echo “Usage: $0 <input_folder> <output_folder>”     exit 1 fi # Create output folder if it doesn’t exist mkdir… Continue reading Sh Code to Convert Files from JPG to WEPB in bulk from a folder

Best practices of integration from Net Suite using web application

Best practices for integrating NetSuite with web applications built using Next.js or Vue.js for product sync and order sync involve using NetSuite’s REST API or RESTlets for scalability and flexibility. Key best practices include secure authentication, choosing the right integration method, handling schema changes, monitoring sync processes, and ensuring data accuracy in real time. Integration… Continue reading Best practices of integration from Net Suite using web application

Monolith to Microservices: Building an Application

Introduction I built a Formula 1 application to manage Teams, Tracks, Drivers, and Races, starting as a monolithic Next.js + Payload CMS app. As my needs grew, I transitioned to a microservices architecture for better scalability, modularity, and autonomy. This article details my process—folder structure, code changes, challenges, and deployment—using my F1 app as an… Continue reading Monolith to Microservices: Building an Application

API Key Strategy for Authentication

To enable API keys on a collection, set the useAPIKey auth option to true. From there, a new interface will appear in the Admin Panel for each document within the collection that allows you to generate an API key for each user in the Collection. import type { CollectionConfig } from ‘payload’ export const ThirdPartyAccess:… Continue reading API Key Strategy for Authentication

RAM Application Workflow – Web application

Customer Authentication:   Login via SO Number/Contact Number: The customer will be able to log in using their SO number or contact number, synchronised with the shopping site’s/NetSuite database.   New Customer Login can be added with a validation concept.(Purchase Bill or Item Serial Number)  Seamless User Interface: Simple and intuitive design to ensure ease of… Continue reading RAM Application Workflow – Web application

State Management in Next.js

State management in Next.js determines how data is stored and shared across components. While React provides built-in state handling with useState, larger applications require more scalable solutions like Context API, Redux, or Zustand. Using Context API import { createContext, useState, useContext } from “react”; const AppContext = createContext(); export function AppProvider({ children }) {  … Continue reading State Management in Next.js

Workflow for the relations on Postgress DB using Payload

Payload CMS uses a schema-based approach to define relationships in the collections configuration. One to One import { CollectionConfig } from “payload/types”; const Users: CollectionConfig = {  slug: “users”,  fields: [   {    name: “profile”,    type: “relationship”,    relationTo: “profiles”, // The related collection    unique: true, // Ensures one-to-one relationship   },  ], }; export default Users; import… Continue reading Workflow for the relations on Postgress DB using Payload

Creating a PostgreSQL database on a server terminal

Access the PostgreSQL Terminal Log in to the PostgreSQL command-line interface using the following command: sudo -u postgres psql This assumes you’re logged in as a user with sudo privileges and postgres is the PostgreSQL administrative user. Create a Database In the psql terminal, run: CREATE DATABASE database_name; Verify the Database Creation You can list… Continue reading Creating a PostgreSQL database on a server terminal