What do you want to save?
Add Code snippet
New code examples
-
Shell/Bash 2021-08-30 02:18:02
how to delete docker images older than x days from docker hub using a shell script serverfault
#!/bin/bash #Script will delete all images in all repositories of your docker hub account which are older than 'X' days set -e # set your username, password and no. of 'X' days value in below lines. #UNAME="YOUR_USERNAME" #UPASS="YOUR_PASS... Add solution -
Python 2021-08-29 14:52:02
Unix time stamp epoch converter
# Unix-time to df.Timestamp = pd.to_datetime(df.Timestamp, unit='s') # Resampling to daily frequency df.index = df.Timestamp df = df.resample('D').mean() # Resampling to monthly frequency df_month = df.resample('M').mean() # Resampling to annual frequ... Add solution -
Javascript 2021-08-29 14:29:02
jest serializes to the same string
describe("toDate", () => { it("should accept times", () => { const dateTime = new Date(); dateTime.setHours(0); dateTime.setMinutes(30); dateTime.setSeconds(0, 0); // error: serializes to same string ... Add solution