I hereby claim:
- I am sharat on github.
- I am sarat (https://keybase.io/sarat) on keybase.
- I have a public key ASCpGYABrDuEUseVITGhBcuQttuLgnVIUdMBtI1yIRQF7Qo
To claim this, I am signing this object:
# Filters the runs based on the status such as failure, cancelled etc., | |
# Filter its `databaseId` with JSON fields, extract the value using `jq` then pipe it to delete | |
gh run list --status=failure --json databaseId --jq '.[] | .databaseId' | xargs -I {} gh run delete {} |
using System.Management; | |
using System.Security.Principal; | |
using Microsoft.Win32; | |
public class SysInfoHelper | |
{ | |
public static void LogSystemInfo(int messageID) | |
{ | |
LogOSVersionInfo(messageID); | |
LogUserInfo(messageID); |
public static class MemoryInfo | |
{ | |
[DllImport("psapi.dll", SetLastError = true)] | |
[return: MarshalAs(UnmanagedType.Bool)] | |
public static extern bool GetPerformanceInfo([Out] out PerformanceInformation PerformanceInformation, [In] int Size); | |
[StructLayout(LayoutKind.Sequential)] | |
public struct PerformanceInformation | |
{ | |
public int Size; |
extension TimeInterval { | |
func stringFormatted() -> String { | |
let interval = Int(self) | |
let seconds = interval % 60 | |
let minutes = (interval / 60) % 60 | |
let hours = (interval / (60*60)) % 60 | |
return String(format: "%02d:%02d:%02d", hours, minutes, seconds) | |
} | |
} |
echo "Upgrading Brew Packages" | |
brew upgrade | |
brew cleanup | |
echo "Upgrading Global NPM Packages" | |
npm upgrade -g | |
echo "Upgrading Gems installed" | |
gem update | |
gem cleanup |
I hereby claim:
To claim this, I am signing this object:
# Change 80 to your desired port. | |
# Use Sudo as appropriate | |
sudo lsof -i :80 |
extension UITextField { | |
func useUnderline() -> Void { | |
let border = CALayer() | |
let borderWidth = CGFloat(2.0) // Border Width | |
border.borderColor = UIColor.red.cgColor | |
border.frame = CGRect(origin: CGPoint(x: 0,y :self.frame.size.height - borderWidth), size: CGSize(width: self.frame.size.width, height: self.frame.size.height)) | |
border.borderWidth = borderWidth | |
self.layer.addSublayer(border) | |
self.layer.masksToBounds = true | |
} |
require('dotenv').config() | |
var kue = require('kue'); | |
console.info('Creating Queue with redis', process.env.REDISCLOUD_URL); | |
var queue = kue.createQueue({ | |
redis: process.env.REDISCLOUD_URL | |
}) | |
console.log('moving forward with kue') |