Skip to content

Instantly share code, notes, and snippets.

View myas92's full-sized avatar

Mohammad Yaser Ahmadi myas92

View GitHub Profile

Convert .mp4 to .gif on ubuntu

1- Install ffmpeg : https://linuxhint.com/convert-video-to-gif-linux/

2- use the below command to create a git with small size

## size 800
ffmpeg -y -i 2.mp4 -filter_complex "fps=5,scale=800:-1:flags=lanczos,split[s0][s1];[s0]palettegen=max_colors=32[p];[s1][p]paletteuse=dither=bayer" output.gif
iyasercoin:
Available
╔════════════════╤═══════════════╤═════════════════╤════════════════╤══════════════╤═══════════════╤═══════════════╤════════════════╤════════════════╤═════════════════╤══════════════╤═══════════════╤═══════════════╤════════════════╤═════════════════╤════════════════╤══════════════╤═══════════════╗
║ iyasercoin.com │ yasercoin.com │ iyasercoins.com │ yasercoins.com │ yaserbit.com │ iyaserbit.com │ yasercoin.net │ iyasercoin.net │ yasercoins.net │ iyasercoins.net │ yaserbit.net │ iyaserbit.net │ yasercoin.org │ iyasercoin.org │ iyasercoins.org │ yasercoins.org │ yaserbit.org │ iyaserbit.org ║
╚════════════════╧═══════════════╧═════════════════╧════════════════╧══════════════╧═══════════════╧═══════════════╧════════════════╧════════════════╧═════════════════╧══════════════╧═══════════════╧═══════════════╧════════════════╧═════════════════╧════════════════╧══════════════╧═══════════════╝
Unvailable
--------------------------------------------------------------------------------------------
developer:
Available
╔═══════════════════╤══════════════════════╤═════════════════════╤════════════════════╤═══════════════════╤══════════════════════╤═════════════════════╤════════════════════╗
║ developerhair.com │ developeroptions.com │ developerbleach.com │ compilerwriter.com │ developerhair.net │ developeroptions.net │ developerbleach.net │ compilerwriter.net ║
╚═══════════════════╧══════════════════════╧═════════════════════╧════════════════════╧═══════════════════╧══════════════════════╧═════════════════════╧════════════════════╝
Unvailable
╔═══════════════╤═══════════════╗
║ developer.com │ developer.net ║
╚═══════════════╧═══════════════╝
KING:
Available
╔═════════════╤═════════════╤══════════════╗
║ kingvon.net │ kingvon.org │ kinghill.org ║
╚═════════════╧═════════════╧══════════════╝
Unvailable
╔══════════╤══════════╤══════════╗
║ king.com │ king.net │ king.org ║
╚══════════╧══════════╧══════════╝
import { Controller, Get, Post, Body, Patch, Param, Delete, Res, HttpStatus, Header } from '@nestjs/common';
import { VideoService } from './video.service';
import { statSync, createReadStream } from 'fs';
import { Headers } from '@nestjs/common';
import { Response } from 'express';
@Controller('video')
export class VideoController {
constructor(private readonly videoService: VideoService) { }
@Get('stream/:id')
import { Injectable } from '@nestjs/common';
import { CreateVideoDto } from './dto/create-video.dto';
import { UpdateVideoDto } from './dto/update-video.dto';
const allVideos = [
{
id: 1,
name: "tom-and-jerry",
duration: '3 mins',
title: 'Tom & Jerry'
},
const express = require('express');
const app = express();
const fs = require('fs');
app.get('/', (req, res) => {
const { size } = fs.statSync('input.txt');
const readStreamfile = fs.createReadStream('input.txt', {
encoding: 'UTF-8',
start: 0,
end: size,
highWaterMark: 10
stages: # List of stages for jobs, and their order of execution
- build
- test
- deploy
build-job: # This job runs in the build stage, which runs first.
stage: build
script:
- cd /home/user/projects/agent
- git pull
@myas92
myas92 / Git.md
Last active April 24, 2022 13:19

Git

don't use username and password

based on this tutoral : link

git config --global credential.helper 'cache --timeout 7200'

How to install docker

  • Docker's internal repos is not supported on 20.04 yet so
  • before installation
    • use a proxy or vpn sudo openconnect 986.9104.945.9196
  • sudo apt-get install -y docker.io based on stackoverflow answer
  • for getting images form dockerhub
  • add nameserver of shekan to /etc/resolve.conf -- (sudo /etc/resolve.conf)
    • nameserver 192.168.1.58
  • nameserver 192.168.1.100