Skip to content

Commit

Permalink
Restructure entire project
Browse files Browse the repository at this point in the history
  • Loading branch information
SoCuul committed Feb 4, 2024
1 parent 4d3047f commit b6bbe5b
Show file tree
Hide file tree
Showing 637 changed files with 58,785 additions and 191 deletions.
2 changes: 1 addition & 1 deletion .gitmodules
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[submodule "libflex/FLEX"]
path = libflex/FLEX
path = modules/libflex/FLEX
url = https://github.com/FLEXTool/FLEX
11 changes: 11 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"editor.tabSize": 4,
"editor.insertSpaces": true,
"editor.trimAutoWhitespace": true,
"editor.formatOnSave": false,
"files.associations": {
"*.x": "objective-c",
"*.m": "objective-c",
"*.h": "objective-c"
}
}
15 changes: 0 additions & 15 deletions BHTBundle.h

This file was deleted.

50 changes: 0 additions & 50 deletions BHTBundle.m

This file was deleted.

9 changes: 2 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,16 +1,11 @@
# SoCuul: Had to add these to get it to compile
SDKVERSION = 14.5
SYSROOT = $(THEOS)/sdks/iPhoneOS14.5.sdk

TARGET := iphone:clang:latest:14.5
TARGET := iphone:clang:14.0
INSTALL_TARGET_PROCESSES = SpringBoard


include $(THEOS)/makefiles/common.mk

TWEAK_NAME = BHInsta

BHInsta_FILES = Tweak.x $(wildcard *.m JGProgressHUD/*.m)
BHInsta_FILES = src/Tweak.x $(wildcard *.m modules/JGProgressHUD/*.m)
BHInsta_FRAMEWORKS = UIKit Foundation CoreGraphics Photos CoreServices SystemConfiguration SafariServices Security QuartzCore
BHInsta_PRIVATE_FRAMEWORKS = Preferences
BHInsta_EXTRA_FRAMEWORKS = Cephei CepheiPrefs CepheiUI
Expand Down
6 changes: 3 additions & 3 deletions build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

PROJECT_PATH=$(pwd)

echo -e '\033[1m\033[32mBuilding BHInstagram project for sideloaded.\033[0m'
echo -e '\033[1m\033[32mBuilding BHInsta project for sideloaded.\033[0m'

make clean
rm -rf .theos
Expand All @@ -11,9 +11,9 @@ make
if [ -e ./packages/com.burbn.instagram.ipa ]; then

echo -e '\033[1m\033[32mBuilding the IPA.\033[0m'
azule -i "$PROJECT_PATH/packages/com.burbn.instagram.ipa" -o "$PROJECT_PATH/packages" -n BHInsta-sideloaded -r -f "$PROJECT_PATH/.theos/obj/debug/BHInsta.dylib" "$PROJECT_PATH/packages/Cephei.framework" "$PROJECT_PATH/packages/CepheiUI.framework" "$PROJECT_PATH/packages/CepheiPrefs.framework" "$PROJECT_PATH/libflex/.theos/obj/debug/libbhFLEX.dylib"
azule -i "$PROJECT_PATH/packages/com.burbn.instagram.ipa" -o "$PROJECT_PATH/packages" -n BHInsta-sideloaded -r -f "$PROJECT_PATH/.theos/obj/debug/BHInsta.dylib" "$PROJECT_PATH/packages/Cephei.framework" "$PROJECT_PATH/packages/CepheiUI.framework" "$PROJECT_PATH/packages/CepheiPrefs.framework" "$PROJECT_PATH/modules/libflex/.theos/obj/debug/libbhFLEX.dylib"

echo -e '\033[1m\033[32mDone, thanks for using BHInstagram.\033[0m'
echo -e '\033[1m\033[32mDone, thanks for using BHInsta.\033[0m'
else
echo -e '\033[1m\033[0;31mpackages/com.burbn.instagram.ipa not found.\033[0m'
fi
Expand Down
6 changes: 3 additions & 3 deletions control
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
Package: com.bandarhl.bhinsta
Name: BHInsta
Version: 0.0.4
Version: 0.1.0
Architecture: iphoneos-arm
Description: An (even more) awesome tweak for Instagram!
Description: A feature-rich tweak for Instagram on iOS!
Maintainer: SoCuul
Author: Bandar Alruwaili
Section: Tweaks
Depends: mobilesubstrate, ws.hbang.common
Depends: mobilesubstrate, ws.hbang.common
1 change: 0 additions & 1 deletion libflex/FLEX
Submodule FLEX deleted from 81f748
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
47 changes: 47 additions & 0 deletions modules/libflex/FLEX/.clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
---
BasedOnStyle: WebKit
AccessModifierOffset: -2
AlignEscapedNewlinesLeft: false
AlignTrailingComments: true
AllowAllParametersOfDeclarationOnNextLine: false
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: false
BinPackParameters: true
BreakBeforeBinaryOperators: false
BreakBeforeBraces: Linux
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
ColumnLimit: 0
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 4
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerBinding: false
ExperimentalAutoDetectBinPacking: false
IndentCaseLabels: true
IndentFunctionDeclarationAfterType: false
IndentWidth: 4
MaxEmptyLinesToKeep: 3
NamespaceIndentation: None
ObjCSpaceBeforeProtocolList: true
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 60
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60
PointerBindsToType: false
SpaceAfterControlStatementKeyword: true
SpaceBeforeAssignmentOperators: true
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
Standard: Auto
TabWidth: 4
UseTab: Never

...
3 changes: 3 additions & 0 deletions modules/libflex/FLEX/.github/FUNDING.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# These are supported funding model platforms

github: [NSExceptional]
27 changes: 27 additions & 0 deletions modules/libflex/FLEX/.github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
---
name: Bug report
about: Report a bug in FLEX
title: ''
labels: bug
assignees: ''

---

### Environment
- Platform+version: **iOS 14** <!--- Change to match your platform and version -->
- FLEX version: **9.9.9** <!--- Change to the version of FLEX you're using -->
<!--- FLEXing / libFLEX users: please include FLEXing and libFLEX versions separately -->

### Bug Report

Here, you can provide a description of the bug. Some tips:

- Please do not paste an entire crash log. Upload the crash log to something like [ghostbin.co](https://ghostbin.co/) or another paste service. Alternatively, you can cut out the relevant stack trace and paste that inside a ` ```code block``` `
- If the bug is more complex than "this button is broken" or a crash, consider including a sample project. For example, if your app's requests aren't showing up in the network history page.
- Providing steps to reproduce is always helpful!
- If you want to include a screenshot or GIF, consider modifying the default markdown for uploaded images to use this code to make the image smaller on desktop:
```
<img width="50%" src=your-image-url >
```

This template is a suggestion. You may format your issue however you want, but generally you should at least include your iOS version and FLEX version.
10 changes: 10 additions & 0 deletions modules/libflex/FLEX/.github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
---
name: Feature request
about: Suggest a new feature for FLEX
title: ''
labels: enhancement
assignees: ''

---


24 changes: 24 additions & 0 deletions modules/libflex/FLEX/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# Xcode
#
build/
*.pbxuser
!default.pbxuser
*.mode1v3
!default.mode1v3
*.mode2v3
!default.mode2v3
*.perspectivev3
!default.perspectivev3
xcuserdata
*.xccheckout
*.moved-aside
DerivedData
*.hmap
*.ipa
*.xcuserstate
.DS_Store
/Example/Pods
Podfile.lock
IDEWorkspaceChecks.plist
*.xcworkspace
.build
12 changes: 12 additions & 0 deletions modules/libflex/FLEX/.travis.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
language: objective-c
xcode_workspace: FLEX.xcworkspace
xcode_sdk: iphonesimulator
before_install:
- gem install xcpretty
matrix:
include:
- xcode_scheme: UICatalog
- xcode_scheme: FLEX
script:
- set -o pipefail
- xcodebuild -workspace $TRAVIS_XCODE_WORKSPACE -scheme $TRAVIS_XCODE_SCHEME -sdk $TRAVIS_XCODE_SDK build | xcpretty
5 changes: 5 additions & 0 deletions modules/libflex/FLEX/.vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{
"search.exclude": {
"Classes/Headers": true
}
}
3 changes: 3 additions & 0 deletions modules/libflex/FLEX/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# Contributing to FLEX #

We welcome contributions! Please open a pull request with your changes.
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
//
// FLEXFilteringTableViewController.h
// FLEX
//
// Created by Tanner on 3/9/20.
// Copyright © 2020 FLEX Team. All rights reserved.
//

#import "FLEXTableViewController.h"

#pragma mark - FLEXTableViewFiltering
@protocol FLEXTableViewFiltering <FLEXSearchResultsUpdating>

/// An array of visible, "filtered" sections. For example,
/// if you have 3 sections in \c allSections and the user searches
/// for something that matches rows in only one section, then
/// this property would only contain that on matching section.
@property (nonatomic, copy) NSArray<FLEXTableViewSection *> *sections;
/// An array of all possible sections. Empty sections are to be removed
/// and the resulting array stored in the \c section property. Setting
/// this property should immediately set \c sections to \c nonemptySections
///
/// Do not manually initialize this property, it will be
/// initialized for you using the result of \c makeSections.
@property (nonatomic, copy) NSArray<FLEXTableViewSection *> *allSections;

/// This computed property should filter \c allSections for assignment to \c sections
@property (nonatomic, readonly, copy) NSArray<FLEXTableViewSection *> *nonemptySections;

/// This should be able to re-initialize \c allSections
- (NSArray<FLEXTableViewSection *> *)makeSections;

@end


#pragma mark - FLEXFilteringTableViewController
/// A table view which implements \c UITableView* methods using arrays of
/// \c FLEXTableViewSection objects provied by a special delegate.
@interface FLEXFilteringTableViewController : FLEXTableViewController <FLEXTableViewFiltering>

/// Stores the current search query.
@property (nonatomic, copy) NSString *filterText;

/// This property is set to \c self by default.
///
/// This property is used to power almost all of the table view's data source
/// and delegate methods automatically, including row and section filtering
/// when the user searches, 3D Touch context menus, row selection, etc.
///
/// Setting this property will also set \c searchDelegate to that object.
@property (nonatomic, weak) id<FLEXTableViewFiltering> filterDelegate;

/// Defaults to \c NO. If enabled, all filtering will be done by calling
/// \c onBackgroundQueue:thenOnMainQueue: with the UI updated on the main queue.
@property (nonatomic) BOOL filterInBackground;

/// Defaults to \c NO. If enabled, one • will be supplied as an index title for each section.
@property (nonatomic) BOOL wantsSectionIndexTitles;

/// Recalculates the non-empty sections and reloads the table view.
///
/// Subclasses may override to perform additional reloading logic,
/// such as calling \c -reloadSections if needed. Be sure to call
/// \c super after any logic that would affect the appearance of
/// the table view, since the table view is reloaded last.
///
/// Called at the end of this class's implementation of \c updateSearchResults:
- (void)reloadData;

/// Invoke this method to call \c -reloadData on each section
/// in \c self.filterDelegate.allSections.
- (void)reloadSections;

#pragma mark FLEXTableViewFiltering

@property (nonatomic, copy) NSArray<FLEXTableViewSection *> *sections;
@property (nonatomic, copy) NSArray<FLEXTableViewSection *> *allSections;

/// Subclasses can override to hide specific sections under certain conditions
/// if using \c self as the \c filterDelegate, as is the default.
///
/// For example, the object explorer hides the description section when searching.
@property (nonatomic, readonly, copy) NSArray<FLEXTableViewSection *> *nonemptySections;

/// If using \c self as the \c filterDelegate, as is the default,
/// subclasses should override to provide the sections for the table view.
- (NSArray<FLEXTableViewSection *> *)makeSections;

@end
Loading

0 comments on commit b6bbe5b

Please sign in to comment.