How to install libwebsocket form git? (discussion with gemenie)

Installing libwebsockets (LWS) directly from GitHub uses standard CMake.

Step-by-Step Installation (Linux / macOS)

1. Install System Dependencies

LWS requires cmake, gcc/g++ (or clang), and SSL headers (OpenSSL/WolfSSL).

  • Ubuntu / Debian:

    Bash
    sudo apt update
    sudo apt install -y git cmake build-essential libssl-dev zlib1g-dev
    
  • Fedora / RHEL / CentOS:

    Bash
    sudo dnf install -y git cmake gcc gcc-c++ openssl-devel zlib-devel
    
  • macOS (Homebrew):

    Bash
    brew install git cmake openssl zlib
    

2. Clone the Official Repository

Clone the repository and check out a stable release tag (recommended over main for production reliability):

Bash
# Clone the repository
git clone https://github.com/warmcat/libwebsockets.git
cd libwebsockets

# (Optional) Checkout a stable release tag
git checkout v4.3-stable

3. Build and Install via CMake

LWS requires an out-of-source build directory:

Bash
# Create and enter build directory
mkdir build && cd build

# Configure build files
cmake .. \
  -DCMAKE_BUILD_TYPE=Release \
  -DCMAKE_INSTALL_PREFIX=/usr/local \
  -DLWS_WITH_SSL=ON \
  -DLWS_WITH_HTTP2=ON

# Compile using all CPU cores
make -j$(nproc)

# Install system-wide
sudo make install

# Refresh shared library link cache (Linux)
sudo ldconfig

Key CMake Options (Customizing Your Build)

You can pass extra flags to cmake .. depending on your requirements:

FlagDefaultDescription
-DLWS_WITH_SSL=ONONEnables OpenSSL/TLS support.
-DLWS_WITH_HTTP2=ONONEnables HTTP/2 protocol support.
-DLWS_WITH_MINIMAL_EXAMPLES=ONOFFBuilds sample client/server code in the build folder.
-DLWS_MAX_SMP=81 / AutoSets maximum SMP thread count for multi-threaded service loops.
-DCMAKE_INSTALL_PREFIX=/usr/usr/localChanges the default installation target directory.

Verifying the Installation

To verify your installation, create a minimal C test file (test.c):

C
#include <libwebsockets.h>
#include <stdio.h>

int main() {
    printf("LWS Version: %s\n", lws_get_library_version());
    return 0;
}
Compile and run it:
Bash
gcc test.c -o test -lwebsockets
./test

How to install llvm-project form git in ubuntu (discussion with chatgpt)

1> git pull https://github.com/llvm/llvm-project.git
2> cd llvm-projct
3> 
cmake -G Ninja \
  -S llvm \
  -B build \
  -DCMAKE_BUILD_TYPE=Release \
  -DLLVM_ENABLE_PROJECTS="clang;clang-tools-extra"
4>
ninja -C build
5> 
sudo cmake --install build

Configure lsp-js for .jsx file in emacs (chatgpt reply unverified)

✅ Step 1: Add jsconfig.json (MOST IMPORTANT)

Create this in your project root:

{
"compilerOptions": {
"target": "ES2020",
"module": "ESNext",
"jsx": "react-jsx",
"allowJs": true,
"checkJs": false
},
"include": ["src"]
}

๐Ÿ‘‰ This alone fixes:

  • random errors
  • unstable suggestions
  • tsserver confusion

✅ Step 2: Clean LSP config (minimal, stable)

Add this in .emacs:

(require 'lsp-mode)

(add-hook 'js-mode-hook #'lsp)
(add-hook 'jsx-mode-hook #'lsp)

;; ๐Ÿ”ฅ reduce noise (important)
(setq lsp-enable-symbol-highlighting nil)
(setq lsp-modeline-diagnostics-enable nil)
(setq lsp-diagnostics-provider :none)

;; optional: faster performance
(setq lsp-idle-delay 0.5)
(setq lsp-log-io nil)

✅ Step 3: Use correct TS server

Make sure installed:

npm install -g typescript

๐Ÿ‘‰ lsp-mode uses tsserver internally


๐Ÿ”ฅ Step 4: Stop the blinking permanently

You already suffered this, so disable the noisy UI parts:

(setq lsp-ui-sideline-enable nil)
(setq lsp-ui-doc-enable nil)

If using lsp-ui.


Command to upgrade python pgAdmin4

source pgadmin4/bin/activate

pip install --upgrade --no-cache-dir pgadmin4

pkill -f pgadmin //to closing exising running instance of previous pgadmin4

pgamdin4 //restart a new pgadmin4 version

Ctrl+z; bg // to make pgadmin4 run in background

deactivate


Pgbouncer related query: Discussion with chatGpt

Query:
Where id pgbouncer config file in ubuntu?

On Ubuntu, the PgBouncer config file location depends on how you installed it.


✅ Default location (APT install)

If you installed via:

sudo apt install pgbouncer

๐Ÿ‘‰ Config file is usually:

/etc/pgbouncer/pgbouncer.ini

๐Ÿ“‚ Other important files

๐Ÿ”น User list (auth file)

/etc/pgbouncer/userlist.txt

๐Ÿ”น Service config (systemd)

/lib/systemd/system/pgbouncer.service

๐Ÿ” Verify actual config path (recommended)

Run:

ps aux | grep pgbouncer

Look for:

pgbouncer /etc/pgbouncer/pgbouncer.ini

๐Ÿ‘‰ That shows the exact file in use


⚡ If running manually

If you started like:

pgbouncer /path/to/custom.ini

๐Ÿ‘‰ Then config is wherever you specified


๐Ÿ”ง Quick check command

pgbouncer -V

or

pgbouncer -h

๐Ÿš€ Typical minimal config example

[databases]
mydb = host=127.0.0.1 port=5432 dbname=mydb

[pgbouncer]
listen_addr = 127.0.0.1
listen_port = 6432
auth_type = md5
auth_file = /etc/pgbouncer/userlist.txt

๐Ÿง  Pro tip (important)

If you modify config:

sudo systemctl restart pgbouncer

✅ Final answer

๐Ÿ‘‰ Most likely your config is:

/etc/pgbouncer/pgbouncer.ini

Food Cooking Safety: (discussions with chatGpt)

Aluminium Prestege Cooker: Can it be used to cook vegitables like chana +potato+tomato sabji moong+tomato sabji Or anything mixed with tomato sabji Yes food can be cooked, but will it cause health harm?

Yes — you can safely cook chana, moong, potato, and tomato-based sabji in an aluminium Prestige cooker. But there are some important scientific nuances you should understand.


๐Ÿ”ฌ What happens with aluminium + food?

4
  • Aluminium naturally forms a thin oxide layer (Al₂O₃) → this acts as a protective barrier.
  • When cooking:
    • Neutral foods (dal, rice, potato) → almost no issue
    • Acidic foods (tomato, tamarind, lemon) → can slightly dissolve aluminium

๐Ÿงช Does aluminium leach into food?

Yes, but quantity matters:

  • Typical leaching:
    • ~1–3 mg per meal (even with acidic food)
  • WHO safe intake limit:
    • ~40 mg/day (for 70 kg adult)

๐Ÿ‘‰ So normal cooking is well within safe limits


⚠️ When does it become a problem?

Risk increases if:

  1. Highly acidic food + long cooking time
    • e.g., tomato-heavy curry pressure cooked long time
  2. Food stored in cooker after cooking
    • overnight storage increases leaching
  3. Old / scratched / pitted cooker
    • damaged oxide layer → more aluminium release

๐Ÿง  Scientific health perspective

  • Aluminium exposure has been studied for links to:
    • Alzheimer's disease
  • Current evidence:
    • No strong causal proof from normal dietary exposure
    • Most aluminium intake actually comes from:
      • food additives
      • processed food
      • water

๐Ÿ‘‰ Cooking in aluminium ≠ major health risk for normal people


๐Ÿฅ˜ Specific to your dishes

✔ Safe:

  • Chana + potato + tomato sabji
  • Moong + tomato sabji

⚠️ Slight caution:

  • Very sour tomato gravy cooked for long time daily
  • Adding lemon/tamarind during pressure cooking

✅ Best practices (practical & rational)

  • Do NOT store food in aluminium cooker → transfer after cooking
  • Avoid very long cooking of acidic food
  • Keep cooker clean, not heavily scratched
  • Occasionally rotate cookware (steel, etc.) if possible

๐Ÿงพ Bottom line

  • ✔ Yes, you can cook mixed vegetable + tomato sabji in aluminium cooker
  • ✔ No significant health harm in normal usage
  • ⚠️ Just avoid prolonged acidic cooking + storage inside cooker

If you want, I can compare aluminium vs stainless steel vs anodized vs pressure cooker types purely from a scientific + durability + cost angle.

suppose viniger is used to curdle milk, panir seperated and water kept Shd this water be used to make atta dough, add instead of normal water in sabji Added to pressure cooker during chana+potato+tomato, moong+tomato sabji, etc ? Any impact on health for this panir-water made using viniger?

Short answer: Yes, you can safely use that water (whey) made with vinegar in dough, sabji, dal, etc. It’s commonly done and is nutritionally useful, not harmful.


๐Ÿงช What exactly is this “paneer water”?

4

When you curdle milk with vinegar:

  • Solid → paneer (protein + fat)
  • Liquid → whey
    • Contains:
      • lactose (milk sugar)
      • whey proteins (small amount)
      • minerals (calcium, potassium)
      • a bit of residual acetic acid (from vinegar)

๐Ÿง  Health impact (science-based)

✔ Safe for normal people

  • No toxicity from vinegar-derived whey
  • Acid level is low and diluted
  • Nutritionally better than plain water

✔ Benefits

  • Slight protein + minerals boost
  • Can improve taste (light tanginess)
  • May help soft dough (acid weakens gluten slightly)

⚠️ When to be cautious

  1. Lactose intolerance
    • Whey still has lactose → may cause gas/bloating
  2. Kidney issues (advanced)
    • Due to minerals (minor concern unless severe condition)
  3. Very large quantity daily
    • Not harmful, but unnecessary acidity in diet

๐Ÿฒ Using it in your cases

✔ Atta dough

  • Good use
  • Softer roti, slight tangy taste

✔ Sabji / dal (chana, moong, potato + tomato)

  • Safe
  • Adds mild sourness (like very light tamarind effect)

✔ Pressure cooker cooking

  • Completely fine

⚠️ Aluminium cooker + whey (important nuance)

You asked earlier about aluminium — here’s the combined effect:

  • Whey is slightly acidic
  • Tomato is acidic

๐Ÿ‘‰ Together → can increase aluminium leaching slightly

But realistically:

  • Still within safe limits if:
    • not overcooked for long time
    • not stored in cooker

✅ Practical best approach

  • ✔ Use whey freely in:
    • dough
    • dal
    • sabji
  • ✔ Especially good for:
    • chana soaking/cooking
  • ⚠️ Avoid:
    • storing whey-based food in aluminium cooker
  • ✔ If cooking very acidic dishes frequently:
    • consider stainless steel occasionally

๐Ÿงพ Bottom line

  • ✔ Vinegar-made paneer water (whey) is safe and useful
  • ✔ No meaningful health harm for normal use
  • ⚠️ Only minor caution with acid + aluminium + long cooking

If you want, I can quantify exact pH, aluminium leaching difference vs plain water, or compare with lemon-curdled whey.

Regarding site Free Browser Tool (https://free-browser-tools.mohitkrgupta.dev) (discussion with google search AI)

Various discussions with Google Search AI regarding site  Free Browser Tool are as below: site free-browser-tools.mohitkrgupta.dev what doe...