APP BLOCKER
- 4 Devlogs
- 11 Total hours
I AM BUILDING AN APP BLOCKER WHICH WILL BLOCK THE APP FOR A SPECIFIC TIME AND THE TIME WOULD BE ENTERED BY YOU AND THIS WOULD BE PROTECTED BY A PASSWORD.
I AM BUILDING AN APP BLOCKER WHICH WILL BLOCK THE APP FOR A SPECIFIC TIME AND THE TIME WOULD BE ENTERED BY YOU AND THIS WOULD BE PROTECTED BY A PASSWORD.
ok so earlier my I made the time tracker and the hardcoded list for particular apps and then merged both of them so that it would just close the hardcoded apps in that list but nw I modified it and took input from the user, ran the terminal command mdfind to check if the app is running or not then used osascript to get the pid of the process and then used that pid to terminate the app. but there was a challenge to find the difference of closed apps and already running apps and after that to keep them blocked till the designated time. so today I worked on that and made a good app blocker which can be used but some modifications like the input of time from the user, input of multiple apps and creating the gui. so after working on that my program would be ready.
let’s go, today I added the loop for my program which was very important because earlier my program was just closing the app if it was running, but the user can again open it. now they couldn’t because I put all of that terminating part inside a loop that would work continuously for that time period.
ok so this is my second declog for this project. today I made the part where I would get the names of all the running processes on my Mac and then I made a list for the apps that I need to block then I compared the all the running processes with the apps I need to block and then just printed that this app needs to be closed just for the testing purpose. now my next work would be to terminate the app and then to modify it I would take the input of the app and time from the user itself and then in the end I would create a good GUI to give it a look of a fully polished project.
ok so this is my first devlog of APP BLOCKER. this is a project where the app would be blocked between a specific period of time. and till now I have made the time system like for the testing purpose it would show blocked if the program is ran between the designated time period and would show allowed if not ran between the designated time. I also learnt about process and learnt how to print all the running processes using psutil (process and system utilities). now my target would be merging them after modifying both the codes