<commit_before>package net.momodalo.app.vimtouch;

import android.app.Activity;
import com.lamerman.FileDialog;
import android.os.Bundle;
import android.os.Environment;
import android.content.Intent;
import java.io.File;
import android.net.Uri;
import android.util.Log;

public class VimFileActivity extends Activity{
    public static final String OPEN_TYPE = "open_type";

    public static final int FILE_TABNEW = 1;
    public static final int FILE_NEW = 2;
    public static final int FILE_VNEW = 3;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);

        int opentype = getIntent().getExtras().getInt(OPEN_TYPE, FILE_TABNEW);

        Intent intent = new Intent(getBaseContext(), VimFileDialog.class);
        intent.putExtra(FileDialog.START_PATH,
                        Environment.getExternalStorageDirectory().getPath());
                                            
        //can user select directories or not
        intent.putExtra(FileDialog.CAN_SELECT_DIR, false);
                                                            
        startActivityForResult(intent, opentype);
	}

    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
        if (resultCode == Activity.RESULT_OK) {
            String filePath = data.getStringExtra(FileDialog.RESULT_PATH);
            Intent intent = new Intent(getBaseContext(), VimTouch.class);
            File file = new File(filePath.replace(" ", "\\ "));
            intent.setData(Uri.fromFile(file));
            intent.putExtra(OPEN_TYPE, requestCode);
            startActivity(intent);
        }<commit_msg>open "." instead of "/sdcard/"<commit_after>package net.momodalo.app.vimtouch;

import android.app.Activity;
import com.lamerman.FileDialog;
import android.os.Bundle;
import android.os.Environment;
import android.content.Intent;
import java.io.File;
import android.net.Uri;
import android.util.Log;

public class VimFileActivity extends Activity{
    public static final String OPEN_TYPE = "open_type";

    public static final int FILE_TABNEW = 1;
    public static final int FILE_NEW = 2;
    public static final int FILE_VNEW = 3;

	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);

        int opentype = getIntent().getExtras().getInt(OPEN_TYPE, FILE_TABNEW);

        Intent intent = new Intent(getBaseContext(), VimFileDialog.class);
        intent.putExtra(FileDialog.START_PATH, ".");
                                            
        //can user select directories or not
        intent.putExtra(FileDialog.CAN_SELECT_DIR, false);
                                                            
        startActivityForResult(intent, opentype);
	}

    protected void onActivityResult(int requestCode, int resultCode, Intent data) {
        if (resultCode == Activity.RESULT_OK) {
            String filePath = data.getStringExtra(FileDialog.RESULT_PATH);
            Intent intent = new Intent(getBaseContext(), VimTouch.class);
            File file = new File(filePath.replace(" ", "\\ "));
            intent.setData(Uri.fromFile(file));
            intent.putExtra(OPEN_TYPE, requestCode);
            startActivity(intent);
        }
{'fraction_non_alphanumeric': 0.09289449400184559, 'fraction_numerical': 0.001845585973546601, 'mean_word_length': 2.6254180602006687, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 6, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '249225', 'n_tokens_mistral': 874, 'n_tokens_neox': 826, 'n_words': 204}