generated from SteamDeckHomebrew/Plugin-Template
-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
begin work on auto-style-commit script
- Loading branch information
Showing
1 changed file
with
14 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/bin/bash | ||
|
||
# TODO: NOT FINISHED | ||
|
||
# This uses macos' sed, which is different from the one in linux | ||
|
||
css_file_path="$(dirname "$0")/src/styles/styles.css" | ||
css_as_string_path="$(dirname "$0")/src/styles/styles-as-string.ts" | ||
|
||
# Read the content of the CSS file, ignoring lines that start with '/*' | ||
css_content=$(sed '/^\s*\/\*/d' "$css_file_path") | ||
|
||
export_header_line_number=$(grep -n "export const styles" $css_as_string_path | cut -d: -f1) | ||
echo export_header_line_number: $export_header_line_number |