This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Make Folder | |
for i in {11..30}; do mkdir S$i; done; | |
make file | |
for i in {1..30}; do cd "S$i"; unlink file.txt; cd ..; done; | |
bulk rename files in a folder | |
for filename in ./*.*; do mv "$filename" "./${filename%.*}.jpg"; done; | |
bulk rename files in a folder to sequential numbers |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$promo = new \Gabievi\Promocodes\Promocodes(); | |
// return $promo->create($amount = 2, $reward = '25', $data = ['intent' => 'sign up promo'], $expires_in = 20, $quantity = 1, $is_disposable = false); | |
//return $promo->output(); | |
//return $promo->createDisposable($amount = 5, $reward = '25', $data = ['intent' => 'sign up promo'], $expires_in = 20, $quantity = null); | |
//return $promo->check('NJJA-4YAQ'); | |
//return $promo->redeem('NJJA-4YAQ'); | |
//return $promo->apply('4PXY-RU2R'); | |
//return $promo->all(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React, { useCallback, useMemo, useState } from 'react'; | |
import PropTypes from 'prop-types'; | |
import { Editor } from "react-draft-wysiwyg"; | |
import { convertToRaw, RichUtils } from "draft-js"; | |
import { convertToHTML } from 'draft-convert'; | |
import DOMPurify from 'dompurify'; | |
import { toast } from 'react-toastify'; | |
import draftToHtml from 'draftjs-to-html'; | |
import "react-draft-wysiwyg/dist/react-draft-wysiwyg.css"; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import SunEditor from 'suneditor-react'; | |
import { | |
align, | |
font, | |
fontColor, | |
fontSize, | |
formatBlock, | |
hiliteColor, | |
horizontalRule, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
100% works for me, i have download all files from aws s3 backet. | |
install aws cli (and select your operating system , follow the steps): | |
https://docs.aws.amazon.com/cli/latest/userguide/install-cliv2.html | |
check aws version: | |
aws --version | |
run config command: | |
aws configure |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. Open run (Win + R) and enter this location => D:\xampp\apache\conf\extra | |
2. Open this file with Any Editor (VS Code recommeded) => httpd-vhosts.conf | |
3. Add this line and save the file | |
<VirtualHost *:80> | |
DocumentRoot "D:/xampp/htdocs/demo-app/demo-api/public" | |
ServerName demo-api.test | |
</VirtualHost> | |
4. Open run (Win + R) and enter this location => C:\Windows\System32\drivers\etc\hosts |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
using System.Threading.Tasks; | |
using System.Security.Cryptography; | |
using System.IO; | |
namespace Your_Namespace | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using Newtonsoft.Json; | |
using Newtonsoft.Json.Linq; | |
public class StringToLongConverter : JsonConverter | |
{ | |
public override object ReadJson(JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer) | |
{ | |
JToken jt = JValue.ReadFrom(reader); | |
return jt.Value<string>(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import React from "react"; | |
import { DatePicker, Button } from "antd"; | |
import styles from "./DateRangeFilter.module.scss"; | |
class DateRangeFilter extends React.PureComponent { | |
handleChange = (value) => { | |
if (!value) return; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Follow this instractions | |
1. Install usig WSL (This step only for windows machine) | |
Windows Subsystem Linux: https://docs.microsoft.com/en-us/windows/wsl/install | |
2. check distribution | |
uname | |
3. install redis | |
sudo apt-get update |