Skip to content

Instantly share code, notes, and snippets.

View mezhevikin's full-sized avatar
:octocat:

Mezhevikin Alexey mezhevikin

:octocat:
View GitHub Profile
@mezhevikin
mezhevikin / ByBitClient.php
Created August 4, 2025 10:30
Lightweight Laravel service for interacting with Bybit’s P2P API. Supports HMAC SHA256 request signing and provides a getAds() method to fetch P2P listings. Uses Laravel’s Http facade and pulls API credentials from config/services.php.
<?php
namespace App\Services;
use Illuminate\Support\Facades\Http;
class ByBitClient
{
private string $baseUrl = 'https://api.bybit.com';
protected int $recvWindow = 5000;
//
// AppIconView.swift
// This view represents a customizable app icon using SwiftUI.
//
// To replace `AppIconView` with your own design:
// - Modify the contents of the `body` to implement your desired app icon layout.
// - You can use any combination of shapes, colors, images, and text.
// - Preview the icon using `AppIconPreview` and save it when you're satisfied.
//
@levochkaa
levochkaa / PublishedAppStorage.swift
Last active October 10, 2023 16:00
@PublishedAppStorage
// PublishedAppStorage.swift
import Combine
import SwiftUI
@propertyWrapper
struct PublishedAppStorage<Value> {
@UserDefault private var storedValue: Value
private var publisher: Publisher?
@dotkebi
dotkebi / NSData+AES.swift
Last active June 12, 2023 08:59
Swift AES Extensions
import Foundation
extension NSData {
func encryptAES128(key: NSString, iv: NSString) -> NSData? {
return aes128(method: CCOperation(kCCEncrypt), key: key, iv: iv)
}
func decryptAES128(key: NSString, iv: NSString) -> NSData? {
return aes128(method: CCOperation(kCCDecrypt), key: key, iv: iv)
@tinyhappysteps
tinyhappysteps / ViewController.swift
Created September 17, 2015 16:40
Swift Resume Audio AVFoundation - AVQueuePlayer AVPlayer
import UIKit
import AVFoundation
var player: AVQueuePlayer!
class ViewController: UIViewController {
override func viewDidLoad() {
super.viewDidLoad()
@JamieMason
JamieMason / unfollow.js.md
Last active November 19, 2025 09:35
Unfollow everyone on twitter.com

Unfollow everyone on twitter.com

By @foldleft.bsky.social, see also Unfollow everyone on bsky.app.

  1. Go to https://twitter.com/YOUR_USER_NAME/following
  2. Open the Developer Console. (COMMAND+ALT+I on Mac)
  3. Paste this into the Developer Console and run it
// Unfollow everyone on twitter.com, by Jamie Mason (https://twitter.com/fold_left)