This file contains hidden or 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
FROM ghcr.io/crytic/echidna/echidna:testing-master | |
RUN apt-get update && apt-get install -y curl | |
RUN ln -s /usr/local/solc-select/scripts/solc-select /usr/bin | |
# Install any solc version is needed for contracts | |
RUN solc-select install 0.8.0 | |
RUN solc-select install 0.8.1 | |
ENV PATH="/root/.solc-select:$PATH" | |
RUN solc-select use 0.8.1 |
This file contains hidden or 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
import os | |
flattened_dir = "./flattened" | |
for filename in os.listdir(flattened_dir): | |
file_path = os.path.join(flattened_dir, filename) | |
if os.path.isfile(file_path) and filename.endswith("_flattened.sol"): | |
with open(file_path, "r") as f: | |
lines = f.readlines() |
This file contains hidden or 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
#!/bin/bash | |
CONTRACTS_DIR="./contracts" | |
FLATTENED_DIR="./flattened" | |
mkdir -p "$FLATTENED_DIR" | |
for FILE in "${CONTRACTS_DIR}"/*.sol; do | |
if [[ -f "$FILE" ]] && [[ -r "$FILE" ]]; then | |
FILE_NAME="$(basename "${FILE%.sol}")" |