CodeEdit App for macOS – Elevate your code editing experience. Open source, free forever.

Overview

CodeEdit for macOS

CodeEdit is a code editor built by the community, for the community, written entirely and unapologetically for macOS. Features include syntax highlighting, code completion, project find and replace, snippets, terminal, task running, debugging, git integration, code review, extensions, and more.

github-banner

All Contributors GitHub branch checks state GitHub Repo stars GitHub forks Discord Badge

⚠️ CodeEdit is currently in development and we do not yet offer a download.
We will post a link here when we have an alpha release ready for testing. Until then, we welcome contributors to help bring this project to life.
    CONTRIBUTE    

Motivation

Developers that use a Mac should be able to use an editor that feels at home on the Mac. Comparable editors are built on Electron. This is a huge limitation because it cannot utilize system resources to their fullest potential.

Electron requires a Chromium instance to run. This can mean massive performance losses and high RAM usage even for small apps built on it. Additionally, the overall code footprint is much larger and animations are slower. More frames are lost and things like window resizing feels laggy. Native apps are smooth as butter and utilize system resources much more efficiently for better performance and reliability. For more information on this, we'll point you to a fantastic article by the nice folks at Remotion.

Xcode offers this great native experience however it mostly supports projects written specifically for Apple platforms. There are many projects not written for Apple platforms that deserve that same macOS-native experience that developers get with Xcode.

This raised the question, what if such an editor existed? We think developers deserve a native experience. This led to the creation of this concept which our project aims to make a reality.

Mission

We think there is room to streamline the developer experience. To gain maximum adoption, CodeEdit should be open source, free to use, and supported by the community.

github-equation

We'd like to keep our application light as TextEdit, but provide an experience similar to Xcode. In other words, we'd like to offer developers the power of a full IDE while remaining lightweight.

Our goal is to develop an app that looks and feels like it was designed and developed by Apple and to closely stick to their design standards and development patterns even down to the application icon and naming strategy.

It might sound crazy, but it is our hope that at some point Apple adopts this project or at least feels like they could.

Community

Join our growing community of amazing contributors on Discord.

Contributing

Read the Contribution Guide

Contributors


Austin Condiff

🎨 💻

Lukas Pistrol

🚇 ⚠️ 💻

Pavel Kasila

🚇 ⚠️ 💻

Marco Carnevali

🚇 ⚠️ 💻

Wesley De Groot

🚇 ⚠️ 💻

Nanashi Li

💻

ninjiacoder

💻

Cihat Gündüz

💻

Rehatbir Singh

💻

Angelk90

💻

Stef Kors

💻

Chris Akring

💻

highjeans

💻

Khan Winter

💻

Jason Platts

🚇 🔌

Rob Hughes

💻

Lingxi Li

💻 🐛

HZ.Liu

💻 🐛

Richard Topchii

💻

Pythonen

💻

Javier Solorzano

💻 🐛

Cosmin Anghel

💻

Shivesh

💻

Andrey Plotnikov

💻

Sponsors

Support CodeEdit's development by becoming a sponsor.

Backers

Support CodeEdit's development by becoming a backer.

Thanks to all of our other backers

@ivanvorobei @albertorestifo

License

Licensed under the MIT license.

Comments
  • 💬 Determine Extension Architecture

    💬 Determine Extension Architecture

    Before moving too far forward with the Extension API and marketplace, we need to decide what type of environment will be used to run extensions.

    ~~JavaScript Core, https://developer.apple.com/documentation/javascriptcore, is an option. It does not support ESM, but as some have mentioned, there are ways to work around these limitations using build tools.~~

    Initially, a Swift extension API is being developed.

    However, we ultimately plan to take an approach similar to Raycast that was described by mathieudutour here, https://github.com/CodeEditApp/CodeEdit/issues/180#issuecomment-1090153684. The architecture involves using node and communicating with the CodeEdit application using JSON-RPC. A react-reconciler will allow extensions to create a custom UI with React components.

    Thank you to everyone who contributed to the conversation! Please feel free to continue to add feedback and/or suggestions.

    enhancement clarification needed extensions PRIORITY 
    opened by jasonplatts 45
  • [WIP] Fix Source Control UI Styling Issues

    [WIP] Fix Source Control UI Styling Issues

    Description

    Fix the remaining UI styling issues per #638 and based on the original design prototype of CodeEdit. (also fix a little formatting issue)

    This PR is still a WIP as the styling of changed files List has animation glitches. Glitches detail is in the comment here and here.

    Related Issue

    • #637
    • #638

    Checklist

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [ ] My changes generate no new warnings
    • [ ] My code builds and runs on my machine
    • [ ] I documented my code
    • [ ] Review requested

    Screenshots

    To be added.

    UI sidebar 
    opened by lilingxi01 37
  • Ability to remove items from recent

    Ability to remove items from recent

    Ability to remove items from the 'recent' list. (see #246)

    Releated Issue

    #246

    Checklist (for drafts):

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [ ] Review requested

    Screenshots (if appropriate):

    image

    Note.

    I don't know how to add it to the MacOS menu bar

    opened by 0xWDG 37
  • Fix and Fine-tune Tab Bar Styles and Interaction Effects

    Fix and Fine-tune Tab Bar Styles and Interaction Effects

    Description

    • Optimize the layout and details to better follow the design prototype of CodeEdit (e.g. divider style, background color, and more).
    • Make tab interactions feel similar with Xcode by optimizing animations, adjust hover effects, etc.
    • [Moved to the future] Fix the hotkey conflict issue (Command-W is not working properly to close tab).
      • This issue seems a bit complicated and out of scope for this PR. So I decided to move it to a separate issue and work with others to resolve it.

    Related Issue

    • #49

    Checklist

    • [x] Tab Bar Style Fine-tuning.
    • [x] Optimizing animations and interactions.
    • [x] ~~Fix the close-tab hotkey issue.~~ (Moved to #473)
    • [x] Add tab bar style preference.
    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] I documented my code
    • [x] Review requested

    Screenshots

    The general styling will be based on the design of Xcode and the initial design concept of CodeEdit.

    Xcode style

    Screen Shot 2022-04-18 at 12 24 04 AM Screen Shot 2022-04-18 at 12 25 08 AM

    Native style

    Screen Shot 2022-04-18 at 12 28 59 AM Screen Shot 2022-04-18 at 12 29 19 AM

    Interaction Demo

    https://user-images.githubusercontent.com/36816148/163754487-a73f7b55-bd62-4407-a918-0efb63ff3e7e.mov

    References

    Here is the animations and interactions of Tab Bar on Xcode.

    https://user-images.githubusercontent.com/36816148/163563123-b77af785-c8f8-42bf-8dc1-2926a17913c1.mov

    opened by lilingxi01 32
  • Add functionality for cloning from git in welcome view

    Add functionality for cloning from git in welcome view

    Description

    This patch adds functionality for cloning a repository from the welcome view. Feel free to point out obvious mistakes as I am taking first touches with Swift world at the same time.

    Related Issue

    • closes #230

    Checklist (for drafts):

    • [x] UI might need some work
    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] Review requested

    Screenshots (if appropriate):

    Näyttökuva 2022-3-24 kello 18 50 47 enhancement UI WIP 
    opened by Pythonen 32
  • Preferences: New UI, Theme Pane implementation, Persistence to `~/.codeedit/` Folder

    Preferences: New UI, Theme Pane implementation, Persistence to `~/.codeedit/` Folder

    Description

    Changes to Preferences

    This PR implements a complete redesign of the Preferences window, coupled with a new way to persist settings. Instead of using UserDefaults settings are now saved to ~/.codeedit/preferences.json. This way one can easily export or import settings manually. It's also possible to sync it across devices using Dotfiles Workflows.

    The main focus of the redesign is the window itself with a new toolbar selector on top (just like Xcode) to navigate to the different sections. Further the Themes section is implemented how it was discussed in #286. The thumbnails of the themes in the sidebar are adaptive to color changes.

    The Editor itself will not adapt to theme changes yet since its implementation is yet work-in-progress Therefore the Preview tab in the Theme section is not yet implemented.

    Theme-specific changes

    Themes are saved in ~/.codeedit/themes/ as a ThemeName.json file. A default theme is provided bundled within the app and gets saved the first time preferences are opened. A template for themes can be found here.

    When a theme gets edited, changes get saved in ~/.codeedit/preferences.json under "theme" > "overrides" > "theme_name". When a theme gets loaded it will override the values found there.

    When a theme was reset, the override properties of this theme get deleted in the preferences.json file.

    When a theme was gets deleted, the original theme_name.json file in ~/.codeedit/themes/ is deleted.

    TODOs

    • [x] Preferences UI overhaul
    • [x] Selectable themes.
    • [x] Use preferences.json instead of UserDefaults for persisting settings.
    • [x] Don't overwrite themes when changing colors. Use preferences.jsons overrides instead.
    • [x] Reset themes (right click > Reset Theme)
    • [x] Implement remaining terminal colors.
    • [x] Delete themes.
    • [x] Enable list view in themes sidebar.
    • [x] Font selector for editor. (not yet functional since new Editor is not implemented yet)
    • [x] Documentation. (partly done) ~- [ ] Duplicate themes.~ (will be implemented later) ~- [ ] Sort themes by category: Bundled, Community, Custom.~ (will be implemented later)

    Releated Issue

    • #34
    • #200
    • #286
    • #344

    Checklist

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] Review requested

    Screenshots

    Editor Theme Settings / Icon Mode

    Screen Shot 2022-04-02 at 17 25 22

    Terminal Theme Settings / List Mode

    Screen Shot 2022-04-02 at 17 25 37

    Changing Colors -> Previews

    https://user-images.githubusercontent.com/9460130/161055774-24ba70bb-ddf7-4748-b4e8-e958a2b6bc9e.mov

    Terminal Tab

    Screen Shot 2022-04-02 at 17 25 54

    Text Editing Tab

    Screen Shot 2022-04-02 at 17 26 46

    Folder structure of ~/.codeedit/

    Screen Shot 2022-04-01 at 14 12 55

    ~/.codeedit/preferences.json

    https://user-images.githubusercontent.com/9460130/161261283-d0c56df2-bad1-4adf-bab7-aebbce9eb0f1.mov

    Reset/Delete Theme

    Screen Shot 2022-04-02 at 17 26 20 enhancement UI 
    opened by lukepistrol 27
  • Preliminary Acknowledgements window and About window fixes

    Preliminary Acknowledgements window and About window fixes

    Description

    Bugs Fixed

    1. The About screen had an issue where the window titlebar had a wrong background:
    Dark Mode Light Mode This change is related to these lines of code:

    https://github.com/CodeEditApp/CodeEdit/blob/e85ea0541c979b97ea447ecd4960d1a3f3b933de/CodeEditModules/Modules/About/src/AboutView.swift#L60-L66

    This PR removes these lines of code and other associated lines, fixing the about screen (tested on macOS 12.3.1 both light and dark mode):

    image image
    1. Very minor change from (c) to the copyright unicode logo.

    Features Added

    1. Added an Acknowledgements screen (Closes #340):

    This PR adds a build phase (that fails silently in case of errors) that copies the generated Package.resolved file from CodeEdit.xcworkspace/xcshareddata/swiftpm/Package.resolved into the Project directory. This file has been added into the project as a reference without copying the file, as a result it'll always be up to date.

    The acknowledgements screen automatically parses this Package.resolved file, therefore needing no separate database file or dependencies, and always staying up to date as the dependencies are updated.

    Includes a simple Regex check to exclude first-party dependencies (i.e. CodeEdit*). Only third party dependencies are parsed and included in the Acknowledgements window, and alphabetical order is maintained.

    Screenshots

    Dark Mode Acknowledgements Light Mode Acknowledgements
    1. This PR also updates the link to the License agreement and opens a browser pointing to the license file in this repo.

    2. This PR also cleans up the text in the About window— moving and splitting a single Text() with multiple \n into separate Text()

    3. Adds hover animations to the git commit hash in the about window:

    Screenshots

    Screen Recording 2022-04-26 at 2 42 08 AM

    1. Makes the version string and the commit hash selectable (and therefore copyable).

    Related Issue

    Adding Acknowledgement Screen:

    • #340

    Fixes some bugs related to About Screen PR:

    • #378

    Checklist

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [ ] Review requested - Will request for a review after Acknowledgements screen is completed.
    opened by mmshivesh 24
  • Using templates for the issues

    Using templates for the issues

    Description

    Using models for issues, I think it would be a good thing. Perhaps you should create two new tags(label) with icons if you want to leave the icons. I believe that the use of icons can give immediate feedback to understand what it is talking about.

    Checklist (for drafts):

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] Review requested

    Screenshots (if appropriate):

    Schermata 2022-03-26 alle 14 28 39 Schermata 2022-03-26 alle 14 28 55 Schermata 2022-03-26 alle 14 29 31 clarification needed 
    opened by Angelk90 22
  • 💬 Identify Preferences Design

    💬 Identify Preferences Design

    How do we want to manage preferences? Let's get a discussion going so we can arrive to the best solution for our users.

    Do we want to sync via iCloud between devices?

    Can project specific settings override global settings?

    How do we want to display these settings?

    Option A 15-macOS-code-edit-preferences

    Option B 15-macOS-code-edit-preferences-1

    Option C 15-macOS-code-edit-preferences-2

    clarification needed WIP 
    opened by austincondiff 22
  • Branch checkout after cloning

    Branch checkout after cloning

    Description

    Added branch checkout modal which shows after cloning from the welcome view

    Related Issue

    Checklist

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] I documented my code
    • [x] Review requested

    Screenshots

    Näyttökuva 2022-4-15 kello 13 03 46 WIP 
    opened by Pythonen 21
  • Add duplicate file functionality

    Add duplicate file functionality

    Description

    • [x] Fixed Duplicate File Functionality
    • [x] Fixed SwiftLint Error

    This is a duplicate of PR #730 by @Blackhole1123. I just carried on with the work. Fixed some merge conflicts and did some finishing touches.

    Some changes had to be made from the initial requirements in #727. Initial requirement wanted the duplicate folder name current_name copy.<extension>. but I was coming across runtime errors when trying to include the space. So the new file are now prefixed with "_" e.g. current_name_copy.<extension>

    Still some issues to resolved:

    • [ ] ~~Upon create duplicate file receive following error Thread 1: EXC_BAD_ACCESS (code=1, address=0x70)(Possibly a new issue)~~
    • [x] New duplicate is created but when renaming it, the file above is selected.
    • [ ] ~~Go to rename file automatically when duplicate file. As per requirement~~

    Related Issue

    • #727

    Checklist

    • [x] I read and understood the contributing guide as well as the code of conduct
    • [x] My changes generate no new warnings
    • [x] My code builds and runs on my machine
    • [x] Review requested

    Screenshots

    https://user-images.githubusercontent.com/80204376/188239240-840d7826-56e4-4b83-af2e-136c90a95f59.mov

    opened by Muhammed9991 19
  • 🐞 Saving a file as Plain Text File creates an empty file

    🐞 Saving a file as Plain Text File creates an empty file

    Description

    All text is lost when saving as Plain Text File.

    To Reproduce

    1. open new CodeEdit window
    2. type some text
    3. save as Plain Text File

    The file is saved but is empty - no text is found. The giving file name is used and the file created at the selected location.

    Expected behavior

    Data should not be lost on save and a Plain Text File should be created with all the text that was there prior to saving.

    Version information

    CodeEdit: 1.0 (0) macOS: 13.1

    Additional context

    No response

    bug 
    opened by foss- 0
  • ✨ create new file should open new editing window with active cursor

    ✨ create new file should open new editing window with active cursor

    Is your feature request related to a problem? Please describe.

    Additional click into new editor window needed to start typing

    Describe the solution you'd like

    Clicking Create new file opens a new window, but cursor is not active. To start typing, a click into the window is needed. To avoid this it would be preferable if new windows opened with active cursor.

    Also clicking into the window is not sufficient to trigger an active cursor. in CodeEdit the first line has to be clicked. This complicates getting started on a document even more.

    Describe alternatives you've considered

    I have nothing to add to this field.

    Additional context

    My use case is using CodeEdit mostly as text editor, so it may deviate from what developers need. But I was surprised about both behaviors:

    • no active cursor on new document
    • clicking in window does not enable active cursor

    macOS 13.1 CodeEdit 1.0. (1)

    enhancement 
    opened by foss- 0
  • ✨ Support saving to Swift file format when creating a new file

    ✨ Support saving to Swift file format when creating a new file

    Is your feature request related to a problem? Please describe.

    No response

    Describe the solution you'd like

    After clicking File -> New to create a file, add an option to save it as a Swift file format Screen Shot 2023-01-05 at 14 50 33 Screen Shot 2023-01-05 at 14 51 30

    Describe alternatives you've considered

    Save the corresponding file format according to the file extension name edited by the user

    Additional context

    .

    enhancement 
    opened by 0407-zh 0
  • [chore]: add bump build number action

    [chore]: add bump build number action

    Updates build number and pushes changes to main after a push to main. The pre-release action needs to be run manually.

    To update the build number we can use Apple's own avgtool which will automatically change the build number in all targets.

    I made the change to only make the pre-release run manually because the changes avgtool makes need to be committed and pushed first.

    Later on when deploying releases with an actual version number changed based on tags we could easily create another action workflow for that where we set the version number to the tag value.

    Any thoughts on this?

    Resources

    • https://medium.com/xcblog/agvtool-automating-ios-build-and-version-numbers-454cab6f1bbe
    • https://developer.apple.com/library/archive/qa/qa1827/_index.html

    Closes #890

    chore 
    opened by lukepistrol 1
  • ✨ Touch bar implementation

    ✨ Touch bar implementation

    Is your feature request related to a problem? Please describe.

    No response

    Describe the solution you'd like

    The code editor to take full advantage of macbook's features, being made for mac in mind. Having the macbook pro touch bars have a "run" and "debug" button would be amazing. Maybe it could even show open tabs of the editor.

    image

    Describe alternatives you've considered

    The touchbar COULD solely be black and not in use, but I feel that would be a waste.

    Additional context

    There could also be customization for the user, allowing the user to choose what they want on their touchbar based on pre-defined presets.

    enhancement nice to have 
    opened by Radictionary 0
  • 🐞 Cursor remains arrow when over editor

    🐞 Cursor remains arrow when over editor

    Description

    Cursor remains an arrow when hovering over editor.

    To Reproduce

    Hover over the editor.

    Expected behavior

    When hovering over editor, cursor should change to an I-beam to indicate editable text.

    bug 
    opened by austincondiff 0
Releases(latest)
Owner
CodeEdit
CodeEdit App for macOS – Elevate your code editing experience. Open source, free forever.
CodeEdit
A curated list of Open Source example iOS apps developed in Swift

 A curated list of Open Source example iOS apps developed in Swift. An amazing list for people who are beginners and learning ios development and for ios developers who need any example app or feature.

Jogendra 752 Dec 31, 2022
An open source package for as-you-type formatting in SwiftUI.

DiffableTextViews An open source package for as-you-type formatting in SwiftUI. Features Feature Description ⌨️ Responsive Formats text as you type ??

Oscar Byström Ericsson 46 Dec 5, 2022
Using Kiva's free API, the demo app retrieves its most recent fundraising loans

KivaLoan Kiva is a non-profit organization with a mission to connect people through lending to alleviate poverty. Using Kiva's free API, the demo app

DaryliOSdev 0 Nov 28, 2021
Fast Swift Views layouting without auto layout. No magic, pure code, full control and blazing fast. Concise syntax, intuitive, readable & chainable. [iOS/macOS/tvOS/CALayer]

Extremely Fast views layouting without auto layout. No magic, pure code, full control and blazing fast. Concise syntax, intuitive, readable & chainabl

layoutBox 2.1k Dec 22, 2022
The source of V2er.iOS

V2er-iOS A beautiful V2EX client built for iOS platform. This project is under develop, is not avaiable in App store yet, you could download it from h

v2er.app 203 Jan 5, 2023
This app presents few examples for common patterns using purer SwiftUI code

VIPERtoSwiftUI GOAL This app presents few examples for common patterns using purer (from authors experience) SwiftUI code. LITERATURE https://www.appy

Tomislav Gelešić 0 Dec 19, 2021
Write less UI code

Layoutless Layoutless enables you to spend less time writing UI code. It provides a way to declaratively style and layout views. Here is an example of

Declarative Hub 428 Oct 9, 2022
Write concise Autolayout code

Winner of Hacking with Swift Recommended award You + Stevia = ?? ?? Write concise, readable layouts ?? Reduce your maintenance time ?? Compose your st

Fresh 3.3k Jan 6, 2023
An easier and faster way to code Autolayout

EZAnchor 中文介绍 An easier way to code Autolayout Are you annoyed of coding .active = true while using Autolayout Anchors over and over again? Are you an

Alex.Liu 25 Feb 20, 2022
The fast path to autolayout views in code

NorthLayout The fast path to autolayout views in code Talks https://speakerdeck.com/banjun/auto-layout-with-an-extended-visual-format-language at AltC

banjun 36 Jul 15, 2022
CompositionalLayoutDSL, library to simplify the creation of UICollectionViewCompositionalLayout. It wraps the UIKit API and makes the code shorter and easier to read.

CompositionalLayoutDSL CompositionalLayoutDSL is a Swift library. It makes easier to create compositional layout for collection view. Requirements Doc

FABERNOVEL 44 Dec 27, 2022
A collection of operators and utilities that simplify iOS layout code.

Anchorage A lightweight collection of intuitive operators and utilities that simplify Auto Layout code. Anchorage is built directly on top of the NSLa

Rightpoint 620 Jan 3, 2023
UIView category which makes it easy to create layout constraints in code

FLKAutoLayout FLKAutoLayout is a collection of categories on UIView which makes it easy to setup layout constraints in code. FLKAutoLayout creates sim

Florian Kugler 1.5k Nov 24, 2022
Written in pure Swift, QuickLayout offers a simple and easy way to manage Auto Layout in code.

QuickLayout QuickLayout offers an additional way, to easily manage the Auto Layout using only code. You can harness the power of QuickLayout to align

Daniel Huri 243 Oct 28, 2022
🎄 Advent of Code ’21 solutions in Swift

Advent of Code '21 My solutions to this years Advent of Code challenge written in Swift. Content Day 1: Sonar Sweep solution Day 2: Dive! solution Day

Witek Bobrowski 2 Dec 1, 2022
A Swift playgrounds with solutions of the Advent of Code 2021 challenge.

?? Advent of Code 2021 ?? A Swift playgrounds with solutions of the Advent of Code 2021. How to run Clone the repo and open the Playground in Xcode. S

Tommaso Madonia 3 Dec 5, 2022
A Code challenge I solved leveraging a lot on Composite collection view layout written in swift

AsthmApp Mobile app designed as a support aid for people with Asthma Accounts Google and Firebase [email protected] dICerytiMPSI Facebook asthmp.ap

null 0 Dec 13, 2021
A Code challenge I solved leveraging a lot on Composite collection view layout...written in swift

Space44 Code Challenge Space44 Code Challenge iOS application for Space 44 hiring process, it leverages on Image download and composite collection vie

null 0 Dec 16, 2021
Fast Swift Views layouting without auto layout. No magic, pure code, full control and blazing fast

Fast Swift Views layouting without auto layout. No magic, pure code, full control and blazing fast. Concise syntax, intuitive, readable & chainable. [iOS/macOS/tvOS/CALayer]

layoutBox 2.1k Jan 2, 2023