Skip to content

Instantly share code, notes, and snippets.

@PathumRathnayaka
PathumRathnayaka / Intellij idea Activate.txt
Last active May 21, 2025 02:49
etBrains products activation 2025
6G5NXCPJZB-eyJsaWNlbnNlSWQiOiI2RzVOWENQSlpCIiwibGljZW5zZWVOYW1lIjoic2lnbnVwIHNjb290ZXIiLCJhc3NpZ25lZU5hbWUiOiIiLCJhc3NpZ25lZUVtYWlsIjoiIiwibGljZW5zZVJlc3RyaWN0aW9uIjoiIiwiY2hlY2tDb25jdXJyZW50VXNlIjpmYWxzZSwicHJvZHVjdHMiOlt7ImNvZGUiOiJQU0kiLCJmYWxsYmFja0RhdGUiOiIyMDI1LTA4LTAxIiwicGFpZFVwVG8iOiIyMDI1LTA4LTAxIiwiZXh0ZW5kZWQiOnRydWV9LHsiY29kZSI6IlBEQiIsImZhbGxiYWNrRGF0ZSI6IjIwMjUtMDgtMDEiLCJwYWlkVXBUbyI6IjIwMjUtMDgtMDEiLCJleHRlbmRlZCI6dHJ1ZX0seyJjb2RlIjoiSUkiLCJmYWxsYmFja0RhdGUiOiIyMDI1LTA4LTAxIiwicGFpZFVwVG8iOiIyMDI1LTA4LTAxIiwiZXh0ZW5kZWQiOmZhbHNlfSx7ImNvZGUiOiJQUEMiLCJmYWxsYmFja0RhdGUiOiIyMDI1LTA4LTAxIiwicGFpZFVwVG8iOiIyMDI1LTA4LTAxIiwiZXh0ZW5kZWQiOnRydWV9LHsiY29kZSI6IlBHTyIsImZhbGxiYWNrRGF0ZSI6IjIwMjUtMDgtMDEiLCJwYWlkVXBUbyI6IjIwMjUtMDgtMDEiLCJleHRlbmRlZCI6dHJ1ZX0seyJjb2RlIjoiUFNXIiwiZmFsbGJhY2tEYXRlIjoiMjAyNS0wOC0wMSIsInBhaWRVcFRvIjoiMjAyNS0wOC0wMSIsImV4dGVuZGVkIjp0cnVlfSx7ImNvZGUiOiJQV1MiLCJmYWxsYmFja0RhdGUiOiIyMDI1LTA4LTAxIiwicGFpZFVwVG8iOiIyMDI1LTA4LTAxIiwiZXh0ZW5kZWQiOnRydWV9LHsiY29kZSI6IlBQUyIsImZhbGxiY

The current kernel/drivers of Fedora 24 do not support the Wifi chip used on my Mac Book Pro. Proprietary Broadcom drivers are packaged and available in the rpmfusion repo.

Verify that your card is a Broadcom using: lspci -vnn -d 14e4:

Sample output:

02:00.0 Network controller [0280]: Broadcom Corporation BCM4360 802.11ac Wireless Network Adapter [14e4:43a0] (rev 03)

Install

Install the rpmfusion repo, note only "nonfree" is required, as the Broadcom Driver is proprietry: http://rpmfusion.org/

@bohwaz
bohwaz / dns_get_record_from.php
Last active May 21, 2025 02:48
PHP script to retrieve a DNS record from a custom nameserver
<?php
/**
* Make a DNS a request to a custom nameserver, this is similar to dns_get_record, but allows you to query any nameserver
* Usage: dns_get_record_from('ns.server.tld', 'A', 'mydomain.tld');
* => ['42.42.42.42']
* @author bohwaz
*/
function dns_get_record_from(string $server, string $type, string $record, string $protocol = 'udp'): array
{
@ProProgrammer
ProProgrammer / My-CV---made-using-HTML-and-CSS.markdown
Last active May 21, 2025 02:48
My CV - Made using HTML / CSS knowledge acquired at Codecademy.com

My CV - made using HTML and CSS

This is my first implementation. I learnt CSS on 15 Jun 2013 at Codecademy.com and as a final project titled "Build your resume!" I took it seriously and decided to go on creating my own Resume using my CSS / HTML knowledge so far (whatever gained from Codecademy.com)

A Pen by Deep Sukhwani on CodePen.

License.

@mattppal
mattppal / security-checklist.md
Last active May 21, 2025 02:47
A simple security checklist for your vibe coded apps

Frontend Security

Security Measure Description
Use HTTPS everywhere Prevents basic eavesdropping and man-in-the-middle attacks
Input validation and sanitization Prevents XSS attacks by validating all user inputs
Don't store sensitive data in the browser No secrets in localStorage or client-side code
CSRF protection Implement anti-CSRF tokens for forms and state-changing requests
Never expose API keys in frontend API credentials should always remain server-side
@awb305
awb305 / cursor-rules.md
Last active May 21, 2025 02:46
.cursorrules

.cursorrules

Project Instructions

Use the project specification and guidelines as you build the app.

Write the complete code for every step. Do not get lazy.

Your goal is to completely finish whatever I ask for.

@Marsgames
Marsgames / 01_DrawableDictionaries.MD
Last active May 21, 2025 02:45
Unity scripts to show dictionaries in the inspector

Dictionaries shown in inspector

Render


  • Put DictionaryDrawer.cs into your Assets/Editor folder

  • Put SerializableDictionary.cs into your Scripts folder

  • Create a custom dictionary

[Serializable] public class CustomDictionary : SerializableDictionary { } 
@zhmu
zhmu / magic_enum_reduced.h
Created February 12, 2023 11:07
Simpler magic_enum which only implements enum_to_string()
// SPDX-License-Identifier: MIT
// Copyright (c) 2023 Rink Springer <rink@rink.nu>
//
// Based on https://github.com/Neargye/magic_enum/blob/master/include/magic_enum.hpp
// Copyright (c) 2019 - 2022 Daniil Goncharov <neargye@gmail.com>.
//
// Permission is hereby granted, free of charge, to any person obtaining a copy
// of this software and associated documentation files (the "Software"), to deal
// in the Software without restriction, including without limitation the rights
// to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
@antruongnguyen
antruongnguyen / git-101-vi.md
Created July 16, 2024 06:22
Git 101 - Hướng dẫn sử dụng git bằng Tiếng Việt

Git 101 - Hướng dẫn sử dụng git bằng bằng dòng lệnh

Đây là bài viết dành cho người mới bắt đầu sừ dụng git, phù hợp cho học sinh, sinh viên, người mới ra trường, hoặc mới đi làm.

Yêu cầu:

  • Git đã được cài đặt trên máy.
  • Cửa sổ dòng lệnh (Terminal/CMD)

1. Git là gì?

Git là một hệ thống quản lý phiên bản phân tán (Distributed Version Control System - DVCS) được sử dụng để theo dõi sự thay đổi trong mã nguồn của phần mềm trong quá trình phát triển. Nó cho phép nhiều người làm việc trên cùng một dự án mà không gặp phải vấn đề xung đột mã nguồn.

@lorey
lorey / selenium_xhr_requests_via_performance_logging.py
Last active May 21, 2025 02:44
Access Chrome's network tab (e.g. XHR requests) with Selenium
#
# This small example shows you how to access JS-based requests via Selenium
# Like this, one can access raw data for scraping,
# for example on many JS-intensive/React-based websites
#
from time import sleep
from selenium import webdriver
from selenium.webdriver import DesiredCapabilities