This file contains 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 { ApolloClient, HttpLink, InMemoryCache, split } from "@apollo/client"; | |
import { GraphQLWsLink } from '@apollo/client/link/subscriptions'; | |
import { createClient } from "graphql-ws"; | |
import { getMainDefinition } from "@apollo/client/utilities"; | |
const scheme = ( proto ) => | |
window.location.protocol === "https:" ? `${ proto }s` : proto; | |
const splitter = ( { query } ) => { | |
const { kind, operation } = getMainDefinition( query ) || {}; |
This file contains 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
name: "Terraform" | |
on: | |
push: | |
branches: main | |
permissions: | |
contents: read | |
jobs: |
This file contains 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
// Reference | |
// https://abr.business.gov.au/Help/AbnFormat | |
public static bool IsValidABN(string abn) | |
{ | |
// return false if null | |
if ( abn == null ) return false; | |
// remove spaces | |
abn = abn.Replace( " ", "" ); |
This file contains 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
# AUTHOR : ADEEL RIZVI | |
# DATE : 24/03/2022 | |
class GoaAttribute: | |
def __init__(self, name, desc, type, required): | |
self.name = name.replace( | |
'-', '_').replace('.', '_').replace(' ', '_') | |
self.desc = desc |
This file contains 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 Header from "../components/header/Header"; | |
function toggleSideBar() { | |
if (Header.MyState.sideBarclassName === "") { | |
Header.MyState.update("sideBarclassName", "active", Header.MyState); | |
} else { | |
Header.MyState.update("sideBarclassName", "", Header.MyState); | |
} | |
} |
This file contains 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
# Author : Adeel Rizvi | |
# Description : My Org asked me to do audit for Nuget packages and export the CSV for each project, I found out that dotnet list doesn't export the csv. | |
# so i wrote the below function to export the output as csv. it only works with command "dotnet list package --vulnerable --include-transitive". | |
# To export the csv download this powershell script and place it on solution folder and run the script. | |
# This script will pull the repos and do the audit and if -ForceUpdate 1 mention it will do major package updates as well and push the branch back to repo. | |
# You want to just run the nuget report run like this >> .\Nuget-Auditor.ps1 | |
# You want to just run the nuget report run & major packages update run like this >> .\Nuget-Auditor.ps1 -ForceUpdate 1 | |
# You want to just run the nuget report & minor packages update run like this >> .\Nuget-Auditor.ps1 -ForceUpdate 1 -UpdateMinorVersion 1 | |
param([bool]$ForceUpdate = 1,[bool]$UpdateMinorVersion = 1) |
This file contains 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
Open RegEdit | |
Goto HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\IDConfigDB\Hardware Profiles\0001 | |
Look for Key "HWProfileGuid" | |
Generate the New GUID or change any number of the GUID lesser than 10. | |
Close RegEdit | |
Try To Activate windows again. |