Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MemoryShield

Screenshot 2026-06-05 at 21 02 53

A lightweight macOS menu-bar utility that watches running processes and reclaims memory before your Mac starts swapping. MemoryShield samples per-process RSS, plots history, and can automatically terminate user apps that stay above a configurable threshold for a sustained duration.

Features

  • Live per-process memory usage with icons, uptime, and percentage of total RAM
  • Configurable memory threshold (MB) and sustain duration (seconds) before action
  • Optional auto-kill of user apps that exceed the threshold
  • Rolling history chart per process
  • Activity log of terminations
  • Native SwiftUI app, no background daemons, no telemetry

Requirements

  • macOS 14 or later
  • Xcode 15+ (for building from source)

Install

From source

make build      # unsigned Release build into ./build
make run        # build and launch
make install    # copy MemoryShield.app to /Applications

Fastlane

bundle install
make fastlane-run
make fastlane-install

Usage

  1. Launch MemoryShield.
  2. Set the Threshold (MB) above which a process is considered a memory hog.
  3. Set the Sustain (s) window — how long a process must stay above the threshold before it is eligible to be killed.
  4. Toggle Auto-kill to let MemoryShield terminate offenders automatically, or leave it off to just monitor.

System processes are filtered out — only user apps are eligible for termination.

Project layout

MemoryShield/
├── MemoryShield/            # SwiftUI sources
│   ├── MemoryShieldApp.swift
│   ├── ContentView.swift
│   └── ProcessMonitor.swift
├── MemoryShield.xcodeproj/
├── fastlane/
├── Makefile
└── Gemfile

Contributing

Issues and PRs are welcome. Please read SECURITY.md before reporting anything that looks like a vulnerability.

License

MIT © Matheus Gois

About

No description, website, or topics provided.

Resources

Security policy

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages