Skip to content

Commit a275a82

Browse files
authored
Merge pull request #2 from ddh4r4m/dev
Update Script for Installation
2 parents 4691100 + 6d1f058 commit a275a82

2 files changed

Lines changed: 122 additions & 12 deletions

File tree

β€ŽREADME.mdβ€Ž

Lines changed: 110 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,13 @@
1-
# 🎨 My Xcode theme - Sundell's Colors
1+
# 🎨 Xcode themes
22

33
This repository contains the Xcode theme that I use. Feel free to use it or modify it to your liking πŸ‘
44

5-
![](Preview.png)
6-
75
## Installing using Swift Package Manager
86

97
The easiest way to install this Xcode theme is to clone this repo and execute `swift run`:
108

119
```
12-
$ git clone https://github.com/JohnSundell/XcodeTheme.git
10+
$ git clone https://github.com/ddh4r4m/XcodeTheme.git
1311
$ cd XcodeTheme
1412
$ swift run
1513
```
@@ -27,7 +25,7 @@ You can also choose to do things manually if you want:
2725

2826
1. Clone this repo:
2927
```
30-
$ git clone https://github.com/johnsundell/xcodetheme.git
28+
$ git clone https://github.com/ddh4r4m/xcodetheme.git
3129
```
3230

3331
2. Create a folder at this path if it doesn't exist already:
@@ -43,8 +41,113 @@ $ git clone https://github.com/johnsundell/xcodetheme.git
4341

4442
6. Should've used the install script, right? πŸ˜‰
4543

44+
## Screenshots
45+
46+
### Ayu Dark
47+
<div style="display: flex;">
48+
<img src="screenshots/Ayu Dark.png" alt="image" width="800" style="margin-right: 10px;">
49+
</div>
50+
<br/> <br/>
51+
52+
### Blueloco Dark
53+
<div style="display: flex;">
54+
<img src="screenshots/Blueloco Dark.png" alt="image" width="800" style="margin-right: 10px;">
55+
</div>
56+
<br/> <br/>
57+
58+
### CRT Green
59+
<div style="display: flex;">
60+
<img src="screenshots/CRT Green.png" alt="image" width="800" style="margin-right: 10px;">
61+
</div>
62+
<br/> <br/>
63+
64+
### Civic
65+
<div style="display: flex;">
66+
<img src="screenshots/Civic.png" alt="image" width="800" style="margin-right: 10px;">
67+
</div>
68+
<br/> <br/>
69+
70+
### Cobalt
71+
<div style="display: flex;">
72+
<img src="screenshots/Cobalt.png" alt="image" width="800" style="margin-right: 10px;">
73+
</div>
74+
<br/> <br/>
75+
76+
### Dracula
77+
<div style="display: flex;">
78+
<img src="screenshots/Dracula.png" alt="image" width="800" style="margin-right: 10px;">
79+
</div>
80+
<br/> <br/>
81+
82+
### Dusk
83+
<div style="display: flex;">
84+
<img src="screenshots/Dusk.png" alt="image" width="800" style="margin-right: 10px;">
85+
</div>
86+
<br/> <br/>
87+
88+
### Flate Arc
89+
<div style="display: flex;">
90+
<img src="screenshots/Flate Arc.png" alt="image" width="800" style="margin-right: 10px;">
91+
</div>
92+
<br/> <br/>
93+
94+
### Flate
95+
<div style="display: flex;">
96+
<img src="screenshots/Flate.png" alt="image" width="800" style="margin-right: 10px;">
97+
</div>
98+
<br/> <br/>
99+
100+
### Monokai Pro
101+
<div style="display: flex;">
102+
<img src="screenshots/Monokai Pro.png" alt="image" width="800" style="margin-right: 10px;">
103+
</div>
104+
<br/> <br/>
105+
106+
### Night Owl
107+
<div style="display: flex;">
108+
<img src="screenshots/Night Owl.png" alt="image" width="800" style="margin-right: 10px;">
109+
</div>
110+
<br/> <br/>
111+
112+
### Noctis Obscuro
113+
<div style="display: flex;">
114+
<img src="screenshots/Noctis Obscuro.png" alt="image" width="800" style="margin-right: 10px;">
115+
</div>
116+
<br/> <br/>
117+
118+
### One Dark Pro
119+
<div style="display: flex;">
120+
<img src="screenshots/One Dark Pro.png" alt="image" width="800" style="margin-right: 10px;">
121+
</div>
122+
<br/> <br/>
123+
124+
### Poimandres Dark
125+
<div style="display: flex;">
126+
<img src="screenshots/Poimandres Dark.png" alt="image" width="800" style="margin-right: 10px;">
127+
</div>
128+
<br/> <br/>
129+
130+
### Slack Aubergine
131+
<div style="display: flex;">
132+
<img src="screenshots/Slack Aubergine.png" alt="image" width="800" style="margin-right: 10px;">
133+
</div>
134+
<br/> <br/>
135+
136+
### Synthwave 84
137+
<div style="display: flex;">
138+
<img src="screenshots/Synthwave 84.png" alt="image" width="800" style="margin-right: 10px;">
139+
</div>
140+
<br/> <br/>
141+
142+
### Tokyo Night
143+
<div style="display: flex;">
144+
<img src="screenshots/Tokyo Night.png" alt="image" width="800" style="margin-right: 10px;">
145+
</div>
146+
<br/> <br/>
147+
148+
46149
## Attributions
47150

48-
This Xcode theme is the result of years of tweaks and modifications to some version of a "Solarized" theme. I have no idea where I got the
49-
original material for this theme from, but if you recognize some aspect of this theme as coming from something you made, feel free to open
151+
This Xcode theme is the result of tweaks and modifications to some version of VSCode themes picked from VSCode MarketPlace. If
152+
you recognize some aspect of this theme as coming from something you made, feel free to open
50153
an issue and I'll gladly add attributions to you πŸ™‚

β€ŽSources/XcodeTheme/main.swiftβ€Ž

Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,16 +25,23 @@ if !fontsFolder.containsFile(named: "SourceCodePro-Regular.ttf") {
2525

2626
print("🎨 Installing Xcode theme...")
2727

28-
let themeURL = URL(fileURLWithPath: #file.replacingOccurrences(of: "Sources/XcodeTheme/main.swift", with: "SundellsColors.xccolortheme"))
29-
let themeData = try Data(contentsOf: themeURL)
28+
// Navigate to the Themes folder
29+
let themesFolder = try Folder.current.subfolder(named: "Themes")
30+
31+
// Get all .xccolortheme files in the Themes folder
32+
let themeFiles = themesFolder.files.filter { $0.extension == "xccolortheme" }
3033

3134
let xcodeFolder = try Folder.home.subfolder(at: "Library/Developer/Xcode")
3235
let userDataFolder = try xcodeFolder.createSubfolderIfNeeded(withName: "UserData")
3336
let themeFolder = try userDataFolder.createSubfolderIfNeeded(withName: "FontAndColorThemes")
3437

35-
let themeFile = try themeFolder.createFile(named: "SundellsColors.xccolortheme")
36-
try themeFile.write(themeData)
38+
for themeFile in themeFiles {
39+
let themeData = try themeFile.read()
40+
let themeDestination = try themeFolder.createFile(named: themeFile.name)
41+
try themeDestination.write(themeData)
42+
print("πŸŽ‰ \(themeFile.name) successfully installed")
43+
}
3744

3845
print("")
39-
print("πŸŽ‰ Sundell's Colors successfully installed")
46+
print("πŸŽ‰ Xcode's Themes successfully installed")
4047
print("πŸ‘ Select it in Xcode's preferences to start using it (you may have to restart Xcode first)")

0 commit comments

Comments
Β (0)