File size: 444 Bytes
6c5b95d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
import pickle

# Define the path to the pickle file
pickle_file_path = 'codesearchdb.pickle'

# Load the pickle file
with open(pickle_file_path, 'rb') as file:
    data = pickle.load(file)



# Save the contents to a new file (for example, a JSON file)
import json

json_file_path = 'codesearchdb.json'
with open(json_file_path, 'w') as json_file:
    json.dump(data, json_file, indent=4)

print(f"Contents have been saved to {json_file_path}")